Summarises a value column by groups (for example a distance curve across patients) into lower, middle and upper quantiles and the number of non-missing values. Quantiles use R's default (type 7) interpolation, which equals the linear rule of common numerical libraries.
See also
Other plot-data builders:
PlotDataBindRows(),
PlotDataConstant(),
PlotDataCount(),
PlotDataCrossShares(),
PlotDataDirection(),
PlotDataDominant(),
PlotDataFromArrays(),
PlotDataJoin(),
PlotDataKeyColours(),
PlotDataLabels(),
PlotDataLonger(),
PlotDataMembership(),
PlotDataPairRatio(),
PlotDataProduct(),
PlotDataRankRows(),
PlotDataRatio(),
PlotDataRecode(),
PlotDataRelative(),
PlotDataSelect(),
PlotDataShares(),
PlotDataSummarise(),
PlotDataUnite()
Examples
d <- data.frame(type = rep(c("a", "b"), each = 6), x = rep(1:2, 6), v = 1:12)
PlotDataQuantiles(d, by = c("type", "x"), value = "v")
#> type x lower median upper n
#> 1 a 1 2 3 4 3
#> 2 a 2 3 4 5 3
#> 3 b 1 8 9 10 3
#> 4 b 2 9 10 11 3