Chart::OFC2::Line - OFC2 Line chart
use Chart::OFC2; use Chart::OFC2::Axis; use Chart::OFC2::Line; my $chart = Chart::OFC2->new( 'title' => 'Line chart test', 'x_axis' => Chart::OFC2::XAxis->new( 'labels' => [ 'Jan', 'Feb', 'Mar', 'Apr', 'May' ], ), ); my $line = Chart::OFC2::Line->new(); $line->values([ 1..5 ]); $chart->add_element($line); print $chart->render_chart_data();
extends 'Chart::OFC2::BarLineBase';
has '+type_name' => (default => 'line'); has 'width' => (is => 'rw', isa => 'Int',);
Dotted line chart
extends 'Chart::OFC2::Line';
has '+type_name' => (default => 'line_dot'); has 'dot-size' => (is => 'rw', isa => 'Int',);
Hollow line chart
extends 'Chart::OFC2::Line::Dot';
has '+type_name' => (default => 'line_hollow');
has '+type_name' => (default => 'area_hollow');
To install Chart::OFC2, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Chart::OFC2
CPAN shell
perl -MCPAN -e shell install Chart::OFC2
For more information on module installation, please visit the detailed CPAN module installation guide.