Hacker News new | past | comments | ask | show | jobs | submit login
Toyplot – A plotting toolkit for Python (toyplot.readthedocs.io)
84 points by aw3c2 on July 29, 2017 | hide | past | favorite | 10 comments



Seems like a fair amount of boilerplate. You really have to specify that the axes are Cartesian with every simple two-axis plot you make?


This is the code from the beginning of the tutorial:

    # make some test data
    import numpy
    x = numpy.linspace(0, 10)
    y = x ** 2
    
    # plot it
    import toyplot
    canvas = toyplot.Canvas(width=300, height=300)
    axes = canvas.cartesian()
    mark = axes.plot(x, y)
3 lines excluding the import doesn't strike me as a remarkable amount of boilerplate


Take a look at their "Convenience API" (http://toyplot.readthedocs.io/en/stable/convenience-api.html) that does indeed make simple two-axis plots a one-liner. toyplot.plot(x, y) seems pretty hard to beat!


Half of my plots use logarithmic scale. Makes sense to me.

I really like the default axis styling where they have gone against the mainstream style of gnuplot/matlab. I'm definitely going to try this out sometime soon.


Seems like an easy thing to make a helper function for.


Am I the only one who gets a bit ticked off when seeing the axis not cross at the origin ?


reminds me on the histograms in R. E.g. http://www.r-tutor.com/elementary-statistics/quantitative-da... They also don't cross and I felt it's aesthetically pleasing in that case ... yet for all plots I agree with you.


Is that a style decision? I haven't seen that before. Seems confusing.


I wish they had more examples for time-series data.


are there any significant benefits over matplotlib?




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: