Add a Histogram
I think a histogram would be a valuable addition to the available charts. I got started on a prototype yesterday but wanted to gather feedback before putting more work in. Does a histogram sound like a good idea? It can technically be accomplished with the existing bar chart but requires you to calculate the bin count and size yourself.
Here is a link to my fork with my start on a histogram. It's pretty functional at this point but doesn't handle all of the options that other charts do. Let me know what you think. https://github.com/dansbits/svg-graph2/tree/histogram-chart
Hi, I have no objections. Did you already have a look at the C3js integration I did? C3js supports a lot more graph types. But as it heavily depends on javascript the real svg will only be rendered by the browser when viewing it. was wondering if that is also compatible with iruby / jupyter.
I believe jupyter should be able to work with C3js but I'd have to look into the details of how to make the JS available in the notebook. It looks like C3 doesn't currently support histograms though. ☹️ I found this issue requesting histograms but it's unresolved.
https://github.com/c3js/c3/issues/750
I think I'll keep going down the path of building it in Ruby if that sounds alright. Any thoughts on minimum functionality to merge into the repo?
no not really. It would be nice if you could create / extend the tests and add an example to the examples folder.
Sounds good. I'll get some base functionality in place and see if I can write some more detailed tests. As well as adding an example. Thanks!
Hi Dan, is this something you still want, and do you have examples of the type of output that you want from this?