guicho271828 / eazy-gnuplot

Super Duper Doopa Booka Lispy Gnuplot library
http://guicho271828.github.io/eazy-gnuplot/
63 stars 8 forks source link

Fix stream based plots with multiple 'using' options #12

Closed mmaul closed 8 years ago

mmaul commented 8 years ago

Multiple 'using' options are not separated by comma and the blank filename parameter '' is not prepended to additional 'using' options. (The blank file name parameter '' specifies that the the current file name ibe used). Furthermore when using the special file name symbol '-' (which is done in %plot when 'using' options are present) the data must be sent once each time for each 'using' option in the plot statement.

Fixed with commit, regression tests passing, added unit test for issue.

guicho271828 commented 8 years ago

Thanks, sounds cool. However, the test does not seem passing on my environment nor on CI. You have pushed it to master, it is okay but instead I recommend you to push to develop, do a self-pullreq and then merge. This makes you sure the test also passes on CI before the merge.

Analysing the output, those commits are not doing what you meant to do. It is like:

plot '-' using 2:xtic(1) title 'Col0' using 2 title 'Col1' using 3 title 'Col2' using 4 title  'Col3'

, not like below:

plot '-' using 2:xtic(1) title 'Col0', '' using 2 title 'Col1', '' using 3 title 'Col2', '' using 4 title  'Col3'
guicho271828 commented 8 years ago

cherry-picked the commits to develop and then reset to master^^ (the original master).

guicho271828 commented 8 years ago

oh, perhaps this is a latest-gnuplot stuff? (gnuplot 5.1)

guicho271828 commented 8 years ago

fixing it anyway.

guicho271828 commented 8 years ago

I enabled a branch protection on master branch. It does not allow direct push, and any other commits should be merged from another branch, e.g. develop. It also does not allow merging until it passes CI testing.

guicho271828 commented 8 years ago

note that you still can merge any new changes when CI tests pass.

mmaul commented 8 years ago

Sorry I did't save the latest changes before I commited sometimes a dynamic environemnt can cut both ways.I should have also commited to a branch.

I like what you did with the format pattern in map-plist block very cool.

With multiple 'using' options, the data still needs to be repeated for each 'using' option. This is fixed in a pull request I am sending.

guicho271828 commented 8 years ago

the data still needs to be repeated --- Oh I didn't realized that. So this is the real result that was expected. beautiful!

mmaul commented 8 years ago

I'm working my way through the GnuPlot Cookbook, to increase my GnuPlot chops and doing ,implementing the examples in the book in eazy-gnuplot as I go. This should help find things that can be improved or fixed and yield some nice examples and plots. I plan on putting them all in an Jupyter notebook and put that in the repository when I'm finished.

guicho271828 commented 8 years ago

If the result can be output in html, would you commit it to gh-pages branch? it would make the doc directly available from the internet.