1Template::Plugin::GD::GUrsaeprh:C:olnitnreisb(u3t)ed PerTlemDpolcautmee:n:tPaltuigoinn::GD::Graph::lines(3)
2
3
4

NAME

6       Template::Plugin::GD::Graph::lines - Create line graphs with axes and
7       legends
8

SYNOPSIS

10           [% USE g = GD.Graph.lines(x_size, y_size); %]
11

EXAMPLES

13           [% FILTER null;
14               USE g = GD.Graph.lines(300,200);
15               x = [1, 2, 3, 4];
16               y = [5, 4, 2, 3];
17               g.set(
18                       x_label => 'X Label',
19                       y_label => 'Y label',
20                       title => 'Title'
21               );
22               g.plot([x, y]).png | stdout(1);
23              END;
24           -%]
25
26           [% FILTER null;
27               data = [
28                   ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug",
29                                                "Sep", "Oct", "Nov", "Dec", ],
30                   [-5, -4, -3, -3, -1,  0,  2,  1,  3,  4,  6,  7],
31                   [4,   3,  5,  6,  3,1.5, -1, -3, -4, -6, -7, -8],
32                   [1,   2,  2,  3,  4,  3,  1, -1,  0,  2,  3,  2],
33               ];
34
35               USE my_graph = GD.Graph.lines();
36
37               my_graph.set(
38                       x_label => 'Month',
39                       y_label => 'Measure of success',
40                       title => 'A Simple Line Graph',
41
42                       y_max_value => 8,
43                       y_min_value => -8,
44                       y_tick_number => 16,
45                       y_label_skip => 2,
46                       box_axis => 0,
47                       line_width => 3,
48                       zero_axis_only => 1,
49                       x_label_position => 1,
50                       y_label_position => 1,
51
52                       x_label_skip => 3,
53                       x_tick_offset => 2,
54
55                       transparent => 0,
56               );
57               my_graph.set_legend("Us", "Them", "Others");
58               my_graph.plot(data).png | stdout(1);
59              END;
60           -%]
61

DESCRIPTION

63       The GD.Graph.lines plugin provides an interface to the GD::Graph::lines
64       class defined by the GD::Graph module. It allows one or more (x,y) data
65       sets to be plotted as y versus x lines with axes and legends.
66
67       See GD::Graph for more details.
68

AUTHOR

70       Thomas Boutell wrote the GD graphics library.
71
72       Lincoln D. Stein wrote the Perl GD modules that interface to it.
73
74       Martien Verbruggen wrote the GD::Graph module.
75
76       Craig Barratt <craig@arraycomm.com> wrote the original GD plugins for
77       the Template Toolkit (2001).
78
79       Andy Wardley <abw@cpan.org> extracted them from the TT core into a
80       separate distribution for TT version 2.15.
81
83       Copyright (C) 2001 Craig Barratt <craig@arraycomm.com>, 2006 Andy
84       Wardley <abw@cpan.org>.
85
86       GD::Graph is copyright 1999 Martien Verbruggen.
87
88       This module is free software; you can redistribute it and/or modify it
89       under the same terms as Perl itself.
90

SEE ALSO

92       Template::Plugin::GD, Template::Plugin::GD::Graph::lines3d,
93       Template::Plugin::GD::Graph::bars, Template::Plugin::GD::Graph::bars3d,
94       Template::Plugin::GD::Graph::points,
95       Template::Plugin::GD::Graph::linespoints,
96       Template::Plugin::GD::Graph::area, Template::Plugin::GD::Graph::mixed,
97       Template::Plugin::GD::Graph::pie, Template::Plugin::GD::Graph::pie3d,
98       GD
99
100
101
102perl v5.28.1                      2006-02-T0e3mplate::Plugin::GD::Graph::lines(3)
Impressum