This document describes usage of Grapher tool
- Internet to download pip packages
- Install the packages:
pip install -r requirements.txt
- Modify configuration file
- Execute below script to create graphs:
python grapher.py -c
- input: input csv filename
- output: output filename. If not provided, it will be same as input
- plot_main_title: plot title (in double quotes)
- plot_sub_title: plot sub title (in double quotes)
- primary_x: x-axis properties
- axis: csv column containing x-axis values. Ex:'users'
- title: axis title. Options: auto/custom_name. Recommended: auto
- ticks: axis ticks. Options: auto/csv-column-containing-x-tick-values/list-of-values. Recommended: auto
- rotation: ticks rotation in degrees. Recommended: 0
- font_size: axis title font size. Recommended: 12
- primary_y: left-y-axis properties
- secondary_y: right-y-axis properties
- axes: csv columns list containing y-axis values. Ex:['cpu','mem']
- labels: alias names for above axes. Options: auto/custom_list
- graph_type: type of plot. Options: bar/line
- title: axis title. Options: auto/custom_name
- font_size: axis title font size. Recommended: 12
- ticks: axis ticks. Options: auto/csv-column-containing-y-tick-values/list-of-values. Recommended: auto
- colors: custom plot colors. Options: auto/list-of-values. Recommended: auto
- limits: y-axis limits. Options: auto/[y_min,y_max]. Recommended: auto
- line_graph_properties: properties for line graphs
- line_width: width of line plot. Recommended: 2.5
- line_style: line plot styles. Options: '-/--/.-'. For complete list, refer here
- markers: to show point markers. Options: True/False
- marker_style: marker style. Recommended: 'o'. Options: 'o/./*'. For complete list, refer here
- marker_size: Size of marker. Recommended: 3
- data_labels: properties for data labels
- show: show data labels. Options: True/False
- precision: precision for data labels. Recommended: 2
- font_size: font size of data labels. Recommended: 8
- grid: grid properties
- show_x_grid: show x-axis grid. Options: True/False
- primary_y: left-y-axis grid properties
- secondary_y: right-y-axis grid properties
- line_style: grid line styles. Options: '-/--/.-'. For complete list, refer here
- line_width: width of grid lines. Recommended: 0.5
- color: grid color. Recommended: 'grey'
- legend: show legend. Options: True/False
- font_style: font family. Recommended: 'Graphik'
- show_tick_limits: show y-axes min and max ticks. Options: True/False
- tick_size: font size of ticks. Recommended: 10
- main_title_size: plot main title fontsize. Recommended: 16
- sub_title_size: plot sub title fontsize. Recommended: 14
- plot_size_in_inches: output plot dimensions (in inches) as [length, width]. Recommended: [10, 6]
- quality_in_dpi: output image quality (higher value indicates better quality). Recommended: 100