Re: [Matplotlib-users] stem plot with horizontal offset (BaseValue)
In fact, I would like to draw other stem plots each at different offset. Ex: -+_-_--+-_--- -+_---+-_--+--_- -+--+-_--+-_- I also found vlines but I have the same problem I don't know how to add a horizontal offset to the values. Ex: import numpy from matplotlib import pyplot x = numpy.arange(10) y = numpy.random.random(10)-0.5 pyplot.vlines(x, 0, y, color='red', bottom=2) # Stems pyplot.plot(x, y, 'D') # Stem ends pyplot.plot([x.min(), x.max()], [0, 0], '--') # Middle bar pyplot.grid(True) pyplot.show() ssinfod -- View this message in context: http://matplotlib.1069221.n5.nabble.com/stem-plot-with-horizontal-offset-BaseValue-tp45297p45300.html Sent from the matplotlib - users mailing list archive at Nabble.com. -- Dive into the World of Parallel Programming The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net/ ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] stem plot with horizontal offset (BaseValue)
Looking at the source code indicates there is a 'bottom' keyword which looks like it controls this, see https://github.com/matplotlib/matplotlib/blob/v1.4.3/lib/matplotlib/axes/_axes.py#L2295 On 31 March 2015 at 19:31, ssinfod wrote: > Hello, > > I found this stem plot example: > http://matplotlib.org/examples/pylab_examples/stem_plot.html > > I would like to add an horizontal offset to the step plot. (Ex: +2 on Y > axis) > What is the equivalent of the Matlab "BaseValue" offset in matplotlib. > > See Reference: > http://www.mathworks.com/help/matlab/ref/stemseries-properties.html > http://stackoverflow.com/questions/21913995/vertically-offset-stem-plot > > Thanks, > ssinfod > > > > > -- > View this message in context: > http://matplotlib.1069221.n5.nabble.com/stem-plot-with-horizontal-offset-BaseValue-tp45297.html > Sent from the matplotlib - users mailing list archive at Nabble.com. > > > -- > Dive into the World of Parallel Programming The Go Parallel Website, > sponsored > by Intel and developed in partnership with Slashdot Media, is your hub for > all > things parallel software development, from weekly thought leadership blogs > to > news, videos, case studies, tutorials and more. Take a look and join the > conversation now. http://goparallel.sourceforge.net/ > ___ > Matplotlib-users mailing list > Matplotlib-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > -- Dive into the World of Parallel Programming The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net/___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] stem plot with horizontal offset (BaseValue)
I’m not going to claim this is the final answer, but in the documentation for the stem function[1], it specifically says that the horizontal line is drawn at 0. A workaround is to subtract the offset from your data, and relabel the axes…. [1]http://matplotlib.org/api/pyplot_api.html?highlight=stem#matplotlib.pyplot.stem On Mar 31, 2015, at 11:31AM, ssinfod wrote: > Hello, > > I found this stem plot example: > http://matplotlib.org/examples/pylab_examples/stem_plot.html > > I would like to add an horizontal offset to the step plot. (Ex: +2 on Y > axis) > What is the equivalent of the Matlab "BaseValue" offset in matplotlib. > > See Reference: > http://www.mathworks.com/help/matlab/ref/stemseries-properties.html > http://stackoverflow.com/questions/21913995/vertically-offset-stem-plot > > Thanks, > ssinfod > > > > > -- > View this message in context: > http://matplotlib.1069221.n5.nabble.com/stem-plot-with-horizontal-offset-BaseValue-tp45297.html > Sent from the matplotlib - users mailing list archive at Nabble.com. > > -- > Dive into the World of Parallel Programming The Go Parallel Website, sponsored > by Intel and developed in partnership with Slashdot Media, is your hub for all > things parallel software development, from weekly thought leadership blogs to > news, videos, case studies, tutorials and more. Take a look and join the > conversation now. http://goparallel.sourceforge.net/ > ___ > Matplotlib-users mailing list > Matplotlib-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/matplotlib-users -- Dive into the World of Parallel Programming The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net/ ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
[Matplotlib-users] stem plot with horizontal offset (BaseValue)
Hello, I found this stem plot example: http://matplotlib.org/examples/pylab_examples/stem_plot.html I would like to add an horizontal offset to the step plot. (Ex: +2 on Y axis) What is the equivalent of the Matlab "BaseValue" offset in matplotlib. See Reference: http://www.mathworks.com/help/matlab/ref/stemseries-properties.html http://stackoverflow.com/questions/21913995/vertically-offset-stem-plot Thanks, ssinfod -- View this message in context: http://matplotlib.1069221.n5.nabble.com/stem-plot-with-horizontal-offset-BaseValue-tp45297.html Sent from the matplotlib - users mailing list archive at Nabble.com. -- Dive into the World of Parallel Programming The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net/ ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] Interactive Applications using Matplotlib
Congrats, Ben. I know you've been working hard on this for a long time and I'm sure it'll be a great value to those looking to use matplotlib beyond just making a quick figure for a report. -Paul — Sent from Mailbox On Tue, Mar 31, 2015 at 11:02 AM, Benjamin Root wrote: > The book I have been working on has now been published! It is about how to > use most of the interactive features that comes with matplotlib in order to > create your own GUI applications. The concepts are taught by building up a > single application piece-by-piece, feature-by-feature. The final chapter > then shows how to bring in tools from other GUIs, and also how to embed > your figure into an existing GUI application (demonstrated for gtk, > tkinter, wx and qt4). > I really hope that the book is useful to the community, and that it is as > enjoyable to read as it was for me to write! > Cheers! > Ben Root > Order it on Amazon > http://www.amazon.com/Interactive-Applications-using-Matplotlib-Benjamin/dp/1783988843/ > Or directly from Packt > https://www.packtpub.com/application-development/interactive-applications-using-matplotlib-- Dive into the World of Parallel Programming The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net/___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
[Matplotlib-users] Interactive Applications using Matplotlib
The book I have been working on has now been published! It is about how to use most of the interactive features that comes with matplotlib in order to create your own GUI applications. The concepts are taught by building up a single application piece-by-piece, feature-by-feature. The final chapter then shows how to bring in tools from other GUIs, and also how to embed your figure into an existing GUI application (demonstrated for gtk, tkinter, wx and qt4). I really hope that the book is useful to the community, and that it is as enjoyable to read as it was for me to write! Cheers! Ben Root Order it on Amazon http://www.amazon.com/Interactive-Applications-using-Matplotlib-Benjamin/dp/1783988843/ Or directly from Packt https://www.packtpub.com/application-development/interactive-applications-using-matplotlib -- Dive into the World of Parallel Programming The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net/___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users