Reputation: 6854
when I use
%matplotlib notebook
import matplotlib.pyplot as plt
I get interactive plots, i.e. I can also zoom into the figure.
For julia this command does not seem to exist. Any ideas?
Upvotes: 4
Views: 3717
Reputation: 1322
Today I am thinking about how to enlarge the plot window interactively without referring to python
or plotly
or something else in Jupiter notebook. And I find a good solution. It is to use the package Interact
. A simple example is as follows. You can get an interactive plot in 3 lines.
import Pkg; Pkg.add("Interact")
using LinearAlgebra, Plots, Interact
@manipulate for n in 10:100, w in 200:1000, h in 200:1000
plot(randn(n),randn(n),seriestype=:scatter,label="n=$(n)",size = (w, h))
end
Upvotes: 2