igraph-help
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [igraph] ( C library ) Parse error reading .net file builded with ig


From: Gábor Csárdi
Subject: Re: [igraph] ( C library ) Parse error reading .net file builded with igraph
Date: Thu, 9 Aug 2012 13:57:26 -0400

So the problem is that you have a vertex called 'la' (#59). This might
seem stupid, and indeed it is. 'la' specifies the label angle in Pajek
.net files, and igraph is looking for the actual numeric angle, and it
is not there.

The solution is to quote the vertex name, i.e. have

59 "la"

in the file. Unfortunately igraph does not look for these reserved
words when it saves pajek files, so this can be considered as an
igraph bug and it will be fixed. We could simply just put all vertex
names in quotes.

For you a workaround would be to replace 'la' with something else,
e.g. 'xla', or quote it (via a program or by hand if you don't need to
do this often) after saving it from igraph. Not the best, but this way
you could use igraph on this data at least.

Thanks for your report, Best,
Gabor

On Thu, Aug 9, 2012 at 1:43 PM, Elena Tea Russo
<address@hidden> wrote:
> Thank you, Gabor.
> I have ho problem in sending my data to the mailing list, but it is quite
> big.
> I've cutted it because the error message said that the problem was in line
> 1.
>
> I am sending to you the whole file. Thank you again.
>
>
> Elena
>
>
> Il giorno 09/ago/12, alle ore 19:27, Gábor Csárdi ha scritto:
>
> Hi!
>
> On Thu, Aug 9, 2012 at 1:07 PM, Elena Tea Russo
> <address@hidden> wrote:
>
> Hi everyone;
>
>
> I am trying to read with igraph (C library) a .net file written using the
>
> igraph library itself.
>
> The .net file has also "id" attributes, and it is something like this:
>
> [...]
>
> When it tryes to read it, it gives to me this error:
>
>
> Error at foreign.c:574 :Parse error in Pajek file, line 1 (syntax error,
>
> unexpected VP_LA, expecting NUM or ALNUM or QSTR), Parse error
>
> Abort trap
>
>
> I am quite perplexed about the fact that igraph cannot read a .net file
>
> written by itself! What is the problem?
>
>
> The part that you included above seems to be fine with the latest
> igraph version. Please send us a file that actually reproduces the
> error, because it seems that the [....] part(s) contain whatever made
> graph fail. If you don't want to send your data to the mailing list,
> then you can just send it to me directly, or (even better) send a
> small part of it that reproduces the error. Thanks.
>
> I have crawled a bit the internet and i have found this bug threat:
>
> https://bugs.launchpad.net/igraph/+bug/602587 – may this be the same? But it
>
> appears like this bug has been fixed, while i continue to ghet the error.
>
>
> Because this is most probably a different error.
>
> G.
>
> Thank to you all for you help
>
>
>
>
> Elena Tea Russo
>
>
>
>
> _______________________________________________
>
> igraph-help mailing list
>
> address@hidden
>
> https://lists.nongnu.org/mailman/listinfo/igraph-help
>
>
>
>
>
> --
> Gabor Csardi <address@hidden>     MTA KFKI RMKI
>
> _______________________________________________
> igraph-help mailing list
> address@hidden
> https://lists.nongnu.org/mailman/listinfo/igraph-help
>
>
>
>
>
>
> _______________________________________________
> igraph-help mailing list
> address@hidden
> https://lists.nongnu.org/mailman/listinfo/igraph-help
>



-- 
Gabor Csardi <address@hidden>     MTA KFKI RMKI



reply via email to

[Prev in Thread] Current Thread [Next in Thread]