NCL Home> Application examples> Special plots || Data files for examples

Boxplots


Note: You must load shea_util.ncl to use the boxplot function.

As the boxplot code does not use a gsn drawing function to construct the boxplot, note that the resources gsnLeftString, gsnCenterString, and gsnRightString will not work with the boxplot function.

box_1.ncl: Default box plot.
box_2.ncl: Demonstrates how to set the color and line thicknesses of individual box plots.

gsLineThicknessF will set the line thickness of the boxes.

boxWidth and boxColors are function local resources that allow you to set width and color of the boxes.
box_3.ncl: Adds some polymarkers.

Uses gsn_add_polymarker (added NCL version 4.2.0.a012) to put the polymarkers on the plot. Recall that this a function that must be set to a dummy variable which is never deleted before the plot is created.
box_4.ncl: Adds some extra text.

gsn_text_ndc is the function used to add the text.
box_5.ncl: Shows how to calculate and plot the median, minimum value, maximum value, and the 25th and 75th percentiles of two timeseries.