Demo codes for Chart::Gnuplot

Data source

Perl arrays of x coordinates and y coordinates script sample image
Perl array of x-y pairs script sample image
Data file (space delimited) script sample image
Mathematical function script sample image
Mixed data source script sample image

Basic chart formatting

Add a chart title script sample image
Add axis labels script sample image
Add legend script sample image
Add grid lines script sample image

2D plotting styles

Lines, points and points on lines script sample image
Dots script sample image
Impulses script sample image
Boxes script sample image
Join with steps, fsteps and histeps script sample image
Filled the curves script sample image
Error bar styles script sample image
Error line styles script sample image
Styles of combination of boxes and error bars script sample image
Smooth the line segments joining data points script sample image

Line and point styles

Line and point color script sample image
Line type script sample image
Line width script sample image
Point type script sample image
Point size script sample image

Range of the plot

User-specified range of the plot script sample image
Semi-autoscale script sample image

Formatting the chart title

Use default settings script sample image
Location script sample image
Font script sample image
Font and font size script sample image
Font color script sample image
Superscript and subscript script sample image
Greek letters script sample image
Composite example script sample image

Formatting the axis label

Use default settings script sample image
Location script sample image
Rotated text script sample image
Font script sample image
Font and font size script sample image
Font color script sample image
Superscript and subscript script sample image
Greek letters script sample image

Formatting the axis tics

Number of minor tics between consecutive major tics script sample image
Specify the tics to label script sample image
Tic label number format script sample image
Tic label font script sample image
Tic label font and font size script sample image
Tic label color script sample image
Location of the tic label script sample image
Rotate the tic label script sample image
Tic length script sample image
Remove the tics on the opposite axis script sample image
Turn on and off the tics script sample image
Composite example script sample image

Formatting the grid lines

Use default settings script sample image
Add minor grid lines script sample image
Line type script sample image
Line width script sample image
Color script sample image
Use another line type for minor grid script sample image
Use another line width for minor grid script sample image
Use another line color for minor grid script sample image
Composite example script sample image

Date and time data

Date data script sample image
Time data script sample image
Change the date time format of the tic labels script sample image

Plot on the secondary axes

Simple example script sample image
Composite example script sample image

Orientation and size

Orientation script sample image
Image size script sample image

3D plots

Plot from Perl array of points script sample image
Plot from data file (space delimited) script sample image
Plot from function script sample image

Multiplot

Image layout script sample image
Composite example script sample image