Conversation
If boxplot option is given, data are expected to be a tuple of five values (median,min,first quartile,third quartile,max) and instead of simple point, boxplot is drawn. Also added a simple example to gallery.
|
Is this different than the candlestick plotter in http://dygraphs.com/tests/plotters.html and #538? |
Although they are visually similar, there are several differences. Boxplot allows you to display basic properties of the distribution behind any generic data, candlestick chart targets financial community only (fixed meaning of colors and shadows). A boxplot requires 5 values to be drawn (the patch do not handle outliers), candlestick needs only 4 (it misses the middle line with median). And there are also some subtle visual differences (the median line, shadow vs whisker). The values displayed by the boxplot can be probably somehow emulated by the candlestick chart and extra serie for the medians. But there would be still the small visual difference that complicates "reading" the graph. |
|
@danvk what do you think about this PR? Do I need to document it more, add more tests or something else is missing? Thanks! |
The PR adds
boxplot: trueoption to plot the data as box plots. The data has to be precomputed, i.e. user specifies values for the whiskers and the box, not raw samples (outliers are not supported).The data are expected to have 5 (median, first and third quartile and position of the whiskers) or 6 values (if the point is not median but average, for example).
An example was added to the gallery to demonstrate this feature.