-
| Hi, Thanks for creating such a wonderful package, I've been having a blast playing around with it. I was wondering how I might go about displaying plots produced by  
 
 begin
    import Pkg
    Pkg.activate(Base.current_project())
    using PythonCall
end@py begin
	import matplotlib as mpl
	import matplotlib.pyplot as plt
	mpl.use("agg")
endp = plt.plot(rand(10))
# p = Python list: [<matplotlib.lines.Line2D object at 0x7fcd403bee90>]plt.show()
# Python None
 Trying  display(p) # returns/displays nothing, regardless of backendUsing the default interactive backend ( At any rate, happy holidays and thanks again for providing this package! | 
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 5 replies
-
| Happy holidays! PythonCall knows how to display a  For example something like plt.plot(.....)
plt.gcf()or fig = plt.figure()
fig.plot(.....)
figshould work. | 
Beta Was this translation helpful? Give feedback.
-
| This is amazing, thanks so much!! Being able to go between inline/gui and julia/python objects so seamlessly feels like witchcraft 🪄 | 
Beta Was this translation helpful? Give feedback.
-
| Do you have a feel for when the next release may be? I thought it would be great to share Pluto notebooks like this one with colleagues to use Pluto's built-in package manager to automatically download and setup Python on their system for them. Currently, the manager can only pull down released packages I think, so the plot under the "Using packages" section cannot be shown just yet. Totally understand if you are trying to add in other things first before tagging the next release though! | 
Beta Was this translation helpful? Give feedback.


Happy holidays!
PythonCall knows how to display a
matplotlib.Figureso you need to return one of those from a Pluto cell.For example something like
or
should work.