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

Add possibility to download graphs in GEXF format #24

Closed
lehkost opened this issue Oct 5, 2018 · 5 comments
Closed

Add possibility to download graphs in GEXF format #24

lehkost opened this issue Oct 5, 2018 · 5 comments
Assignees

Comments

@lehkost
Copy link
Member

lehkost commented Oct 5, 2018

The CSV format we offer for download is limited in what it can comprise. We should start slowly to build a GEXF export. The first version could just comprise what the CSV comprises, but on top of the IDs also feature the labels, i.e., character names from <persName> (or, <name>, for person groups). – Here is an easy example how to build the GEXF format.

@cmil
Copy link
Member

cmil commented Oct 9, 2018

A first version is of GEXF output is now available with 0.24.0. See for example https://dracor.org/api/corpus/ger/play/wieland-alceste/networkdata/gexf. Please test.

@cmil cmil assigned lehkost and unassigned cmil Oct 9, 2018
@lehkost
Copy link
Member Author

lehkost commented Oct 9, 2018

Cool! 🏄 It looks like it works in Gephi, here's Emilia Galotti:
emilia-gefx-in-gephi
We could easily add weight, I guess, like so:

<edge id="der_prinz|conti" source="der_prinz" target="conti" weight="2" />

And since we collect gender info, we can add it to node properties:

<attvalues>
  <attvalue for="gender" value="FEMALE"></attvalue>
</attvalues>

This is so much better than working with plain CSV, thanks for the swift implementation.

@cmil
Copy link
Member

cmil commented Oct 10, 2018

Version 0.25.0 provides both weight and gender.

@lehkost
Copy link
Member Author

lehkost commented Oct 10, 2018

Just tested it, seems to work nicely!

One other obvious thing to provide on a per-node basis would be the number of words per character (i.e., everything within <sp>/<p> and <sp>/<l> (including <emph>, but excluding <note> and <stage> within <sp>…).

It would add to our visualisations to align the node sizes with the number of words per character, an aspect we can't visualise at the moment…

@cmil
Copy link
Member

cmil commented Oct 10, 2018

@lehkost since the calculation of the number of words may be a bit more complex but at the same time beneficial for other issues let's deal with it in a separately addressable issue.

@cmil cmil closed this as completed Oct 10, 2018
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

2 participants