the main page of manual

Input XML file

Input XML file examples

Source code of XML files used to generate the graphs on the main page: data-med.xml and data-sincos.xml.

Structure of the XML file

<?xml version='1.0' encoding='utf-8'?>
<graph version='1'>
   <option name='error_show' value='1' />
   <option name='count_x_labels' value='5' />
    <row label='pop1'>
      <value value='1' />
      <value value='2' />
   <row label='pop2'>
      <value value='3' />
      <value value='4' />

The elements option, row a value repeat as needed.

Options attributes

attribute name description
count_x_labels number of x-axis legend labels
count_y_labels number of y-axis legend labels
shift_y_labels shift of y-axis labels (px)
rounding_y_labels rounding of y-axis legend labels (0 - integers, 1 - one decimal number, -1 - rounding to tens)
count_horizontal_lines number of horizontal lines
count_vertical_lines number of vertical lines
width width of the graph area (px)
height height of the graph area (px)
margin_horizontal horizontal margin of the graph area from the border of the image (px)
margin_vertical vertical margin of the graph area from the border of the image (px)
margin_graph relative inner margin between height of graph curve and the border of the graph area
format_image the format of an output image (png|gif|jpg) - JPG isn't considered a good choice
antialiasing antialiasing (1|0) 1 = yes
error_show Show errors (1|0) 1 = yes; option 1 is suited for debugging; option 0 tries to draw a graph (with default values), and shows error only if necessary
color_surround surrounding color (all colors in RRGGBB format)
color_background background color
color_lines inner lines color
color_outline border color
color_text text color
color_graph1 graph curve color - in case you have more than one data serie (more curves), you can also use color_graph2 and so on; otherwise, color_graph1 is used for all series


  • only the dot (period, full stop, ..) is accepted as the decimal mark
  • the number of data series (curves) depends on the number of value elements in the first element row; extra values in later lines are reported as errors when error reporting is on; otherwise, extra values are ignored, and if a row is missing some values, a discontinuous graph will be drawn
  • the total width of the graph image is equal to width+2*margin_horizontal
    the total height of the graph image is equal to height+2*margin_vertical
  • x-axis legend labels aren't required;
    the number of labels displayed will be equal to or less than the requested value - the first and last labels are always displayed and the rest of them are shown with uniform margins (according to their divisibility)