A Grammar of Graphics for SciRuby

74 views
Skip to first unread message

Eduardo Silva Araújo

unread,
Feb 14, 2018, 9:47:55 PM2/14/18
to SciRuby Development
Hello! I'm a student willing to join you on this year's Google Summer of Code.

I saw that one of the ideas was bringing matplotlib to sciruby. It makes sense, since it is
powerful, widely used, and nice. Reading this, I remembered doing some awesome
plots using ggplot2, from R. What do you think about it? Do you think it would be nice
to have a grammar of graphics based plotting utility for sciruby?

Thanks in advance!

Victor Shepelev

unread,
Feb 22, 2018, 9:05:05 AM2/22/18
to SciRuby Development
Hi Eduardo!

The idea sounds nice in general, yet huge to implement. Do you have already some plan/ideas of how you could implement that? 

V.

--
You received this message because you are subscribed to the Google Groups "SciRuby Development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sciruby-dev+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

John Woods

unread,
Feb 23, 2018, 3:52:36 PM2/23/18
to sciru...@googlegroups.com
Over the last several years we've explored numerous plotting grammars. I think the feeling is that we need something like matplotlib because people are extremely familiar with it — not because it's the most versatile or powerful. I'm extremely hesitant to say we should add another grammar when we haven't done anything to support the grammars we've already implemented.

John

--
You received this message because you are subscribed to the Google Groups "SciRuby Development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sciruby-dev...@googlegroups.com.

Eduardo Silva Araújo

unread,
Feb 24, 2018, 8:08:57 PM2/24/18
to SciRuby Development
 I understand your position. When I asked about a grammar of graphics, was with ggplot2 in mind, because of familiarity as well. matplotlib is awesome, and having it available somehow would be great. I may be wrong, since I haven't used matplotlib as much as ggplot2 in R, but I have the impression that ggplot's interface would mix more nicely with ruby, and might result in better user experience.

I miss a plotting utility for ruby, and I'd happy to have either ggplot or matplotlib in it.

> The idea sounds nice in general, yet huge to implement. Do you have already some plan/ideas of how you could implement that?

I skimmed ggplot's source, it is huge. I was thinking about designing the library structure and implementing some of the more used features.

Matplotlib is huge as well; I'll take a closer look at its source to sketch a plan.

John Woods

unread,
Feb 28, 2018, 10:56:31 AM2/28/18
to sciru...@googlegroups.com
I think the key take-away when you look at matplotlib's source should probably not be, "Oh, this is exactly how we should do it," but rather, "This is one possible approach." Remember that matplotlib's syntax is based on matlab's, so you could also look at GNU Octave.

*Definitely* worth considering is how they actually do the cross-platform GUI generation. It seems pretty reliable.

I think it'd also be nice to "ruby-ize" the syntax just a bit. That is, it should still function like matlab plotting; but I'd like to see a little more consistency/logic/principle of least surprise in how more complicated plotting works. It may be that your ultimate product is somewhere between matplotlib and ggplot2, too.

I'm glad you're interested in this project. I think it's the single largest bottleneck for Ruby as a scientific language.

Eduardo Silva Araújo

unread,
Mar 3, 2018, 8:35:29 PM3/3/18
to SciRuby Development
I'll organize some thoughts and start a more properly named thread. Thanks for the feedback!
Reply all
Reply to author
Forward
0 new messages