Note: This addon document is for an older version of GRASS GIS that will be discontinued soon. You should upgrade your GRASS GIS installation, and read the current addon manual page.
d.vect.colbp draws a boxplot of the values in a vector map attribute column. The user can use the where option to only select a subset of the attribute table. There is also the option to group the values of the column according to the categories in a second column (group_by and create one plot with for each group a separate boxplot.
By default, the resulting plot is displayed on screen (default). However, the user can also save the plot to file using the plot_output option. The format is determined by the extension given by the user. So, if plot_output = outputfile.png, the plot will be saved as a png file.
There are a few additonal layout options, including the option to rotate the plot and the x-axis labels. Furthermore, the user can optinally plot the boxplot(s) with notches and without outliers.
This script, based on d.vect.colhist, is a quick and dirty solution sing basic matplotlib, and will need some further fine-tuning and testing.
d.vect.colbp -n map=schools_wake column=CORECAPACI where="CORECAPACI >0"
Figure 1: Boxplot of core capacity of schools in Wake County.
d.vect.colbp -h --overwrite map=schools_wake column=CORECAPACI where="CORECAPACI >0" group_by=ADDRCITY order=ascending
Figure 2" Boxplot of core capacity of schools in Wake County, grouped by city.
Available at: d.vect.colbp source code (history)
Latest change: Mon Jun 28 07:54:09 2021 in commit: 1cfc0af029a35a5d6c7dae5ca7204d0eb85dbc55
Note: This addon document is for an older version of GRASS GIS that will be discontinued soon. You should upgrade your GRASS GIS installation, and read the current addon manual page.
Main index | Display index | Topics index | Keywords index | Graphical index | Full index
© 2003-2023 GRASS Development Team, GRASS GIS 7.8.8dev Reference Manual