An alternative to NVD3.js (reusable charts library)? [closed]
Asked Answered
V

1

9

I've been looking recently at solution for creating charts for a web page.

After a bad experience with (an outdated version) of Highcharts, I tried to give a chance for D3.js, which I find very handy.

Since I'm on a tight schedule for this project, I'm trying to find a library for reusable charts that sits on top of D3.
So far the only candidates I found are Miso Project's d3.chart and NVD3.js.

The problems are that d3.chart is only a tiny framework for making reusable charts, while NVD3 is very extensive, but not very flexible and very undocumented.

Is there an alternative to those libraries (or should I start writing one)?

Vories answered 11/7, 2013 at 20:17 Comment(4)
I find that, much to the time, Mike Bostock's examples (the ones on the main d3 gallery page) can be readily adapted for most needs. No documentation beyond the basic d3 stuff, but they're readily tweakable.Decoy
THe NVD3 source is very readable. And is usually enough.Retardant
@WolfgangCodes, it's a fairly large codebase, and not clear on immediate review. I found it hard to rely strictly on the code to do what I was trying to do (i.e. change the X axis scale to a time scale and set its domain to one I specify). A project of this magnitude shouldn't be left without proper documentation.Vories
I agree while heartedly. And it is very difficult to get it to do something it wasn't intended to do, especially because it doesn't have proper documentation. There have been numerous times when I've struggled to add functionality to it. I plan to consider d3.chart for my next big effort.Retardant
G
14

Did you check out Vega?

I do agree with ckersch's comment above that, in the long run, writing your own visualization from the ground up with d3 is usually appropriate... and fun. (Of course this also depends on what you're actually trying to accomplish.)

Personally, I would not recommend writing your own framework because, chances are, it won't be reusable beyond your current project.

Gametangium answered 11/7, 2013 at 20:39 Comment(7)
That is very intriguing! Thank you! I'm not sure it will be my eventual choice, but will keep an eye on it. You're probably right about writing my own library, but D3 definitely deserves something of that sort.Vories
@Vories Same here –– not sure I'll ever use it, but I'm keeping an eye on it.... On an unrelated note: I checked out your github. Cool stuff! In case you're interested in moving to NYC, let me know. The hummus is not as good here, but still...Gametangium
Haha, thanks! Maybe some day, NYC does sound appealing, but still trying to make it out here (and enjoying the hummus) :DVories
FYI, Vega is authored by Jeff Heer who was Mike Bostock's advisor when Mike was a PhD student at Stanford.Tallula
meetamit -- great tip! Thanks for mentioning Vega. Also great comment by @kanitw. After reading what Jeff Heer says about the relationship of Vega to D3, and seeing how easy it is to work with, I think Vega is going to be great for a majority of uses. I'm definitely giving it a shot. github.com/trifacta/vega/wiki/Vega-and-D3Pope
Above link by @Pope has moved to github.com/vega/vega/wiki/Vega-and-D3 Having heard about D3 and not Vega, the moment I opened up Vega, I thought how it compares with D3 because obviously, it's an important factor to consider when a dev is shortlisting options. Besides Vega looking top-notch, it's extremely impressive that they compared it with D3 in full detail. Even without completing reading the whole thing, I'm sold on Vega.Laurenlaurena
How does Vega compare to NVD3 in 2016?Marrakech

© 2022 - 2024 — McMap. All rights reserved.