PTVS plotting pandas Dataframes and Series with matplotlib in python debug interactive

880 Views Asked by At

Is it possible to plot pandas objects inside the PTVS interactive debugger? Is it possible to save plots to disk as jpeg's?

I think I was able to do this when I first started using PTVS (last year, its awesome by the way!) but I just tried again and I dont get any plots appearing. I cant remember if I had to do something special to get this to work and from doing some google searches I get a confusing picture of the current best practice in this regard.

I want to be able to plot diagrams from my debug interactive window, similar to what is shown on this pandas tutorial.

http://pandas.pydata.org/pandas-docs/stable/visualization.html

Is this possible?

Visual Studio Professional 2013 update 4 (latest I think) PTVS 2.1.21008.00 (latest I think)

All help is greatly appreciated.

-Jason

[edit: more info on this http://pytools.codeplex.com/discussions/574776 ]

1

There are 1 best solutions below

0
On

Unfortunately not. The regular interactive has an IPython mode that, among other things, enables inline plots. But the Debug interactive doesn't have that.

You can, of course, still load matplotlib in the Debug interactive and tell it to plot things. But because there's no integration of event loops between it and VS in that mode, the plots will basically work like modal windows - you won't be able to continue debugging or otherwise interact with VS until you close the plot window.