3 ms·
So I want to plot a few lines and label my axes. First step? Install 2 of the 3, ... er, 4 available plotting packages, named "Winston" and "Gertrude," or "Je
by username223 13y ago
So I want to plot a few lines and label my axes. First step? Install 2 of the 3, ... er, 4 available plotting packages, named "Winston" and "Gertrude," or "Jenkins" and "Marsalis," or something else equally meaningless. Once I've done this, I can issue a bunch of low-level commands to produce my simple plot.
Matlab may be an ugly language, but offering this kind of amateur software as a replacement is just pathetic. Octave, R, and various python packages have been viable for years.
- maximilian 13y agoAssuming you have matplotlib installed: using PyPlot x = linspace(0,2*pi,1000); y = sin(3*x + 4*cos(2*x)); plot(x, y, color="red", linewidth=2.0, linestyle="--") title("A sinusoidally modulated sinusoid")
- capnrefsmmat 13y agoYou can use Gadfly to plot using the grammar of graphics (as implemented by R's ggplot2), which is the nicest plotting API I've seen: http://dcjones.github.io/Gadfly.jl/ http://dcjones.github.io/Gadfly.jl/ Julia aims for a different niche than R or Python, and is far more performant than Octave.
- jordigh 13y ago> Julia aims for a different niche than R or Python, and is far more performant than Octave. Julia's loops are more performant. Its vectorised code is not. http://stackoverflow.com/questions/19208014/is-the-julia-language-really-as-fast-as-it-claims http://stackoverflow.com/questions/19208014/is-the-julia-lan...
- idunning 13y agoIt is open-source software, not a walled garden - there are going to be multiple options, and they are not going to all be named ["PLOTTINGISHERE$i" for i in 1:4]. If you like MATLAB/pyplot/matplotlib style, PyPlot.jl is for you. If you like ggplot2, Gadfly.jl is for you. If you like gnuplot, Gaston.jl is for you. Finally, but not least, is Winston.jl, which is its own thing altogether. I think in many cases its good for packages that overlap to come together/one to become dominant, but I don't think that applies here. https://github.com/stevengj/PyPlot.jl https://github.com/stevengj/PyPlot.jl https://github.com/dcjones/Gadfly.jl https://github.com/dcjones/Gadfly.jl https://github.com/mbaz/Gaston.jl https://github.com/mbaz/Gaston.jl https://github.com/nolta/Winston.jl https://github.com/nolta/Winston.jl
- username223 13y agoI guess Gaston would be my choice, since I'm most familiar with Gnuplot syntax for tweaking plots. Still, it's a shame Julia inherited the Ruby/Rails convention of making up nonsense names for packages. While they don't need to be named PLOTTING$i, it wouldn't hurt for them to be named Plot::Gnuplot, etc. (or whatever the syntax is for nested names). Doing otherwise is just putting branding ahead of actually trying to help people.