wucke13 / RustGnuplot

A Rust library for drawing plots, powered by Gnuplot.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

RustGnuplot

A Gnuplot controller written in Rust.

Build Status

Documentation

See here

Examples

A simple example:

let mut fg = Figure::new();
fg.axes2d()
	.set_title("A plot", &[])
	.set_legend(Graph(0.5), Graph(0.9), &[], &[])
	.set_x_label("x", &[])
	.set_y_label("y^2", &[])
	.lines(
		&[-3., -2., -1., 0., 1., 2., 3.],
		&[9., 4., 1., 0., 1., 4., 9.],
		&[Caption("Parabola")],
	);
fg.show().unwrap();

Simple example plot

A somewhat involved 2D example (see example1.rs in the examples directory):

Complicated example plot

Features

  • Simple 2D plots
    • lines
    • points
    • points + lines
    • error bars
    • ...and more!
  • Simple 3D plots
    • surface plots
    • heatmaps
    • contours

Building

Via Cargo

cargo build

About

A Rust library for drawing plots, powered by Gnuplot.

License:GNU Lesser General Public License v3.0


Languages

Language:Rust 97.9%Language:Python 2.1%