gnuplot v1.19.88 Gnuplot View Source
Interface to the Gnuplot graphing library.
Plot a sine function where Gnuplot generates the samples:
Gnuplot.plot([
~w(set autoscale)a,
~w(set samples 800)a,
[:plot, -30..20, 'sin(x*20)*atan(x)']
])
Plot a sine function where your program generates the data:
Gnuplot.plot([
[:plot, "-", :with, :lines :title, "sin(x*20)*atan(x)"]
],
[
for x <- -30_000..20_000, do: [x / 1000.0 , :math.sin(x * 20 / 1000.0) * :math.atan(x / 1000.0) ]
]
)
Link to this section Summary
Functions
Build a comma separated list from a list of terms
Build a comma separated list of two terms
Build a comma separated list of three terms
Build a comma separated list of four terms
Build a comma separated list of five terms
Build a comma separated list of six terms
Transmit commands without dataset
Transmit commands and datasets to Gnuplot
Link to this section Types
command()
View Source
command() :: [command_term(), ...]
command() :: [command_term(), ...]
command_term() View Source
Link to this section Functions
list(xs) View Source
Build a comma separated list from a list of terms.
list(a, b) View Source
Build a comma separated list of two terms.
list(a, b, c) View Source
Build a comma separated list of three terms.
list(a, b, c, d) View Source
Build a comma separated list of four terms.
list(a, b, c, d, e) View Source
Build a comma separated list of five terms.
list(a, b, c, d, e, f) View Source
Build a comma separated list of six terms.
plot(commands) View Source
Transmit commands without dataset.
plot(commands, datasets) View Source
Transmit commands and datasets to Gnuplot.
Examples
iex> Gnuplot.plot([[:plot, "-", :with, :lines]], [[[0, 0], [1, 2], [2, 4]]])
{:ok, "plot "-" with lines"}