ipython notebook
명령을 치면 내부적으로 로컬 웹서버가 실행되면서 Jupyter라는 이름으로 웹페이지가 뜬다.Pkg.add("IJulia")
Pkg.update()
INFO: Nothing to be done INFO: METADATA is out-of-date — you may not have the latest version of IJulia INFO: Use `Pkg.update()` to get the latest versions of your packages INFO: Updating METADATA... INFO: Updating cache of ImmutableArrays... INFO: Updating cache of GZip... INFO: Updating cache of FixedPointNumbers... INFO: Updating cache of ZMQ... INFO: Updating cache of Reactive... INFO: Updating cache of Optim... INFO: Updating cache of Gadfly... INFO: Updating cache of Images... INFO: Updating cache of DataArrays... INFO: Updating cache of Distributions... INFO: Updating cache of DataFrames... INFO: Updating cache of FactCheck... INFO: Updating cache of JSON... INFO: Updating cache of SIUnits... INFO: Updating cache of BinDeps... INFO: Updating cache of DataStructures... INFO: Updating cache of Compose... INFO: Updating cache of Compat... INFO: Updating cache of Docile... INFO: Computing changes... INFO: Upgrading BinDeps: v0.3.12 => v0.3.14 INFO: Upgrading Compat: v0.4.6 => v0.4.9 INFO: Upgrading Compose: v0.3.12 => v0.3.13 INFO: Upgrading DataArrays: v0.2.15 => v0.2.16 INFO: Upgrading DataFrames: v0.6.6 => v0.6.7 INFO: Upgrading DataStructures: v0.3.9 => v0.3.10 INFO: Upgrading Distributions: v0.7.3 => v0.7.4 INFO: Upgrading Docile: v0.5.6 => v0.5.12 INFO: Upgrading FactCheck: v0.2.7 => v0.2.8 INFO: Upgrading FixedPointNumbers: v0.0.7 => v0.0.8 INFO: Upgrading GZip: v0.2.15 => v0.2.17 INFO: Upgrading Gadfly: v0.3.12 => v0.3.13 INFO: Upgrading Images: v0.4.38 => v0.4.39 INFO: Upgrading ImmutableArrays: v0.0.7 => v0.0.8 INFO: Upgrading JSON: v0.4.3 => v0.4.4 INFO: Upgrading Optim: v0.4.1 => v0.4.2 INFO: Upgrading Reactive: v0.2.0 => v0.2.2 INFO: Upgrading SIUnits: v0.0.3 => v0.0.4 INFO: Upgrading ZMQ: v0.1.18 => v0.1.19 INFO: Building Images INFO: Building ZMQ
Pkg.update()
명령으로 인하여 설치된 Julia 패키지들이 전부 업데이트 된 것을 볼 수 있음.using PyPlot
INFO: Loading help data...
i = [0 : 0.001 : 2*pi]
6284-element Array{Float64,1}: 0.0 0.001 0.002 0.003 0.004 0.005 0.006 0.007 0.008 0.009 0.01 0.011 0.012 ⋮ 6.272 6.273 6.274 6.275 6.276 6.277 6.278 6.279 6.28 6.281 6.282 6.283
x = sin(i)
y = cos(i)
6284-element Array{Float64,1}: 1.0 1.0 0.999998 0.999996 0.999992 0.999988 0.999982 0.999976 0.999968 0.99996 0.99995 0.99994 0.999928 ⋮ 0.999937 0.999948 0.999958 0.999967 0.999974 0.999981 0.999987 0.999991 0.999995 0.999998 0.999999 1.0
plot(x,y)
1-element Array{Any,1}: PyObject <matplotlib.lines.Line2D object at 0x7f27d88334d0>
plot(x,y)
axis("equal")
grid("on")
title("Circle in Julia Lang")
PyObject <matplotlib.text.Text object at 0x7f27d8726a10>