Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Write.gexf does not export UTF-8 characters correctly #20

Open
gvegayon opened this issue Jul 6, 2014 · 0 comments
Open

Write.gexf does not export UTF-8 characters correctly #20

gvegayon opened this issue Jul 6, 2014 · 0 comments

Comments

@gvegayon
Copy link
Owner

gvegayon commented Jul 6, 2014

Originally reported by: Guillem Vicens (Bitbucket: gvicens, GitHub: gvicens)


Hi George,

in R when exporting with write.gexf UTF-8 encoding for special characters (accents and the like) seem to get lost. As it seems the export is done to UTF-8 without BOM.

I have reproduced this by doing following steps:

  1. loading the graph data from 2 .CSV encoded in UTF-8 .1.
  2. Generate a graph by using the igraph package. This graph is used in my code to perform several calculations
  3. Generate the nodes and edges data frames. Up until this point all is correctly encoded in UTF-8.
  4. Use write.gexf to generate the .GEXF file. At this point encoding gets lost.

I also tried using both Encoding(x) and enc2utf8(x) with no success at all.

I have attached a minimal example to reproduce the problem. Session info is also included.

Thanks for any help!


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant