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

Chart library #38

Open
oscargus opened this issue Nov 21, 2015 · 11 comments
Open

Chart library #38

oscargus opened this issue Nov 21, 2015 · 11 comments

Comments

@oscargus
Copy link

I was maybe thinking of adding a database information dialog, showing different statistics about the database (just because I can). It would be nice to plot some things, so any opinions on adding a chart library and in that case which?

http://www.jfree.org/jfreechart/ seems to be the most competent, but then it is rather large and also supports lots of things which is not of primary interest.

https://github.com/eseifert/gral seems more suitable in many ways, but no Maven support (yet).

@koppor
Copy link
Member

koppor commented Nov 21, 2015

For the other readers:

I'm currently fearing that gral is dead. But if gral produces better looking results, use that. We'll surely manage pushing it to maven central somehow.

example galleries

packaging consideration:

@oscargus
Copy link
Author

JFreeChart probably produces better looking results but as stated in the comparison it is 2.6 MB vs 300 kB. Not sure if it is worth to add 2.6 MB of dependencies for a few plots... But then, I'm not really sure how it works later on. Is everything included in the Jabref jar or only the used parts?

@oscargus
Copy link
Author

xchart might also be an option: https://github.com/timmolter/XChart http://knowm.org/open-source/xchart/

Example gallery: http://knowm.org/open-source/xchart/xchart-example-code/

Small footprint and available on Maven. Only obvious drawback is that there's currently no pie chart (which I had some plans for).

@tobiasdiez
Copy link
Member

@piecharts: Letting speak the master Edward Tufte himself:

A table is nearly always better than a dumb pie chart; the only worse design than a pie chart is several of them, for then the viewer is asked to compare quantities located in spatial disarray both within and between charts [...] Given their low density and failure to order numbers along a visual dimension, pie charts should never be used.

So better just use bar charts 👍

@oscargus
Copy link
Author

The particular use case was to illustrate the proportion of different entry types, for which I think a pie chart will do an excellent job.

@oscargus
Copy link
Author

One should note that there's a difference between "scientific" visualization and more "colorful" visualization, where I'd say that any statistics related to bibtex-files would fall in the latter category... It should just look nice...

@koppor
Copy link
Member

koppor commented Nov 21, 2015

The jar is always packaged completely in the resulting jar. JabRef is already large (approx 23 MB), then 10% more is not an issue.

Currently JabRef is not as colorful as version 2.11. See #40 for color examples for JabRef 3.0. - Don't know how colorful diagrams fit into our nearly flat style.

@oscargus
Copy link
Author

Colorful may be the wrong word. The point is that whatever statistics we can produce from a database will only be used for fun, not to actually analyze anything important (as far as I can tell).

@koppor
Copy link
Member

koppor commented Nov 22, 2015

Got it :). Just use the library where you think it is the most convenient to use. GRAL will be on maven central soon. A first look reveals that GRAL is more Java-like than XChart which seems to be more C-like. Don't know about JFreeChart.

@simonharrer
Copy link

In JavaFX a lot of these things are supported out of the box. Maybe we should postpone complex diagrams and only print data without visualization, doing preparation work.

@oscargus
Copy link
Author

May make sense to wait until JavaFX indeed. There may show up some printed statistics though.

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

No branches or pull requests

4 participants