IPython 2.0 introduced interactive widgets, which are basically:
Thanks to fantastic work by a Google Summer of Code student, Shashi Gowda, the same features are accessible from a Julia interface.
In [1]:
using Interact
In [2]:
@manipulate for n in 1:100
rand(n,n)
end
Out[2]:
In [3]:
using Colors
@manipulate for r in 0:0.1:1, g in 0:0.1:1, b in 0:0.1:1, n in 1:100
linspace(RGB(0.0,0.0,0.0), RGB(r,g,b), n)
end
Out[3]:
In [4]:
using PyPlot
In [5]:
x = linspace(0,10,1000)
clf()
f = figure()
@manipulate for α = 1:0.1:4, β = 1:0.1:4, leg="a funny plot"
withfig(f) do
plot(x, cos(α*x + sin(β*x)))
legend([leg])
end
end
Out[5]:
In [7]:
using SymPy
x = Sym("x")
@manipulate for n=0:20
latex(SymPy.diff(sin(x^2), x, n))
end
Out[7]:
In [ ]: