Unable to use mathplotlib in scientific mode

Answered

Hi,

I am not sure if I have missed anything. I have just installed PyCharm 2017.3 today and when I import mathplotlib, and do plt.show() in my python console, nothing happened. 

The instruction below said that graph should be plotted in the SciView box:

https://www.jetbrains.com/help/pycharm/scientific-mode-support.html

I need help to get this work.

Best,

Louis

26 comments
Comment actions Permalink

Hi Louis8799! Do you have Settings | Tools | Python Scientific | Show plots in toolwindow option enabled?

0
Comment actions Permalink

Hi Pavel, I'm having a similar issue. I have Scientific Mode turned on and "Show plots in toolwindow" enabled but the plot does not appear in the SciView window. Thanks.

0
Comment actions Permalink

Hi Pavel and Eric,

I restarted PyCharm and it works........

no idea at all.

0
Comment actions Permalink

+1 on having this issue.  Did this ever get resolved?  I have the same issue and I'm just wondering if there was more to the setup than simply installing pycharm.  Is there an additional setting that needs to be set?

0
Comment actions Permalink

I upgraded from Pycharm community to professional to have this type of functionality and it just doesnt work. Nothing in shown in the "Sciview" plots. Plots just appear in a separate window. I have scientific mode enabled and "Settings | Tools | Python Scientific | Show plots in toolwindow" enabled. I tried this with the sample plotting code on the Pycharm help page as well.

The "Data" viewer also seems broken: dataframes with quotes on the column headers cannot be plotted.

I find this a bit dissapointing for "professional" and have reverted back to the "community" edition despite the license i bought.

2
Comment actions Permalink

I'm also having issues with this, 

I've made sure to check the "show plots in toolwindow" setting but am still getting plots in separate windows

0
Comment actions Permalink

Same problem. Checked "Show plot in toolwindow" still plot window popping out.

0
Comment actions Permalink

I had the same issue, I'm on PyCharm Professional 2018.1 trial, here is what solved it for me:

  • I uninstalled all previous versions of PyCharm (community, professional), removing all settings
  • I installed JetBrain Toolbox and logged in
  • I installed a fresh PyCharm Professional from within the JetBrain Toolbox, without importing any settings

Then I could run the sample code on the Scientific Mode Tutorial help page and it showed the 2 plots in the SciView toolbar as it should.

Hope this helps.

0
Comment actions Permalink

Pycharm scientific works in Ubuntu but doesn't work in windows 10. And why would you use "JetBrain Toolbox" just for installing PyCharm?

0
Comment actions Permalink

I have the same issue. Plot window keeps popping up as floating, even when I have show plots in tool window set. Windows 10. Just uninstalled and reinstalled pycharm. Didn't help. Running Anaconda.

0
Comment actions Permalink

Hi Andrew, could you please specify PyCharm version you are using?

0
Comment actions Permalink

2018.1.4. (Re)Installed it yesterday from latest download.

0
Comment actions Permalink

And it's the commercial version.

0
Comment actions Permalink

same problem with 2018.1.2 professionnial on Mac OS 10.11.6.

 

I can't get any plot, with our without ticking the box in tools.

 

thanks

0
Comment actions Permalink

Walter, do you use a remote interpreter? Please file a ticket in our bug tracker: https://youtrack.jetbrains.com/issues/PY

0
Comment actions Permalink

Andrew, I created a separate issue for your problem: PY-30454. Could you please take a screenshot of the plot popup and attach it there? Also please specify matplotlib version you are using.

0
Comment actions Permalink

On windows 10 it's always matplotlib popup window, irrespective of what you select/deselect in settings. This issue is never resolved since I put up comment in April.

0
Comment actions Permalink

@Paveil yes indeed I have figured out that it is only with a remote (Docker for instance) interpreter. Do I have to create a ticket ? Is it something that should work ?

thanks

0
Comment actions Permalink

@Walter, unfortunately, docker is not supported with matplotlib, the relevant comment: https://youtrack.jetbrains.com/issue/PY-18102#focus=streamItem-27-1412306-0-0

0
Comment actions Permalink

@Sanjeev, I reproduced it finally, looks like it works ok on the pure virtualenv, but fails on Anaconda. We'll take a look on the cause. I am sorry it took so long.

3
Comment actions Permalink

@Pavel, will be happy to see it working with Anaconda on win10, all nicely stacked plot windows within pycharm!. That's what i use at work.!

0
Comment actions Permalink

I was able to plot matplotlib in sciview from a remote python intepreter with a workaround described here: https://youtrack.jetbrains.com/issue/PY-27489

0
Comment actions Permalink

I am running with a remote interpreter and cannot get any plots, no matter what I do. Needless to say, plotting is required in my python runs. My workaround is to login to the remote via a shell terminal and run manually when I want a plot.

Ridiculous. Is there an ETA on when plotting will be supported by Pycharm?

 

BTW: I would prefer a full plot window rather than sciview as the plots are much better without sciview (e.g. I can ZOOM).

1
Comment actions Permalink

@Petewills

Plots should already work with remote interpreter without additional configuration. I tested with Windows 10 as a client and Ubuntu 18.04 as server, the plots showed right away.

We do have a few issues opened with plots on remote interpreters:

https://youtrack.jetbrains.com/issue/PY-33052

https://youtrack.jetbrains.com/issue/PY-32668

https://youtrack.jetbrains.com/issue/PY-32178

Please check if your case is related to any of them, and try the workarounds from there. If this is not helpful, I would suggest to submit a support request, and we would gladly investigate your case.

https://intellij-support.jetbrains.com/hc/en-us/?pycharm

0
Comment actions Permalink

@Petewills did you find a solution to this? I have the same issue with the remote server. Also agree with the wanting a full plot window!

0
Comment actions Permalink

I am able to plot now but I got it working a while back so it is fuzzy. 

I do not use scientific mode - I think I disabled it in the settings but it keeps trying to come back - I don't let it.

Now, when running remotely, I simply use matplotlib commands and they run on the remote and display a window on my local machine. It gives normal matplotlib graphics.

0

Please sign in to leave a comment.