question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Missing options to control inline plots look

See original GitHub issue

How does Spyder change plt.savefig() behavior? Comparison below. This creates major discrepancy between what Spyder generates and other applications (e.g. Jupyer, sphinx-gallery), while I need them to be same. Can Spyder be made to match terminal python example.py?


import matplotlib.pyplot as plt

plt.plot([1, 2])
plt.gcf().set_size_inches(6, 4)
plt.gcf().set_dpi(72)
plt.gcf().savefig("img.png")

Command prompt:

image

Spyder

image

with

image

Issue Analytics

  • State:open
  • Created a year ago
  • Comments:8 (8 by maintainers)

github_iconTop GitHub Comments

1reaction
ccordoba12commented, Oct 17, 2022

Ok, no problem. I moved it to Spyder 6 because is not critical.

1reaction
dalthvizcommented, Oct 17, 2022

I don’t think so. I guess this then should go to the v5.x millestone or to the v6.0alpha1 one?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Plot pane resolution is too low and missing matplotlib ... - GitHub
You didn't look hard enough. That option is in. Tools > Preferences > IPython console > Graphics > Inline backend > Resolution.
Read more >
Plot inline or a separate window using Matplotlib in Spyder IDE
I know that in Spyder, click Tools, Preferences, Ipython Console, Graphics and under Graphics Backend select “automatic” instead of “inline”.
Read more >
Plots in R Markdown code chunks are shown in plots pane ...
Click on that, and you will see many options to control the output view. Make sure you have selected "Chunk Output Inline" and...
Read more >
Plots — Spyder 5 documentation
The options menu in the top right of the Plots pane offers several ways to customize how your plots are displayed. Mute inline...
Read more >
2.6 R code chunks and inline R code | R Markdown - Bookdown
You have fine control over all these output via chunk options, ... R plots in code chunks are first recorded via a graphical...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found