mquantile: Conditional and joint multivariate quantiles

Description Usage Arguments Details Value Examples

Description

Quantiles of observations in multivariate space.

Usage

1
2
3
cond_cdf(x, pltype, ngrid, ...)

joint_cdf(x, pltype, ngrid, ...)

Arguments

x

vector, matrix, or data.frame of observations.

pltype

character, plot type, one of c('none','cdf','pairs','rgl','persp').

ngrid

vector, number of grid points.

...

further arguments passed to other functions.

Details

Where:
X = n x m matrix,
EPDF = empirical probability distribution function (density), and
ECDF = empirical cumulative distribution function;

Then three possible multivariate quantiles are:

[1] Marginal quantile: from ECDF of raw data for EACH axis independently (so yields m separate vectors each of length n).

[2] Joint quantile: from ECDF of raw data across ALL m axes simultaneously (so yields 1 vector of length n); always monotonically increasing toward higher axis values.

[3] Conditional quantile: from the ECDF of the EPDF of ALL m axes simultaneously (so yields 1 vector of length n); monotonically increasing toward lower density values, but may vary with respect to axis values.

Conditional quantiles are analogous to data depth methods; current implementation allows 1-6 dimensions. Joint quantiles are analogous to Pareto frontiers; current implementation allows 1-3 dimensions.

Value

Plots to device, or else object of class 'zzz'.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
# iris data
x <- iris[,1:3]
cond_cdf(x, 'pairs')
joint_cdf(x, 'pairs')
cond_cdf(x, 'rgl')
joint_cdf(x, 'rgl')

# dustbunny data
set.seed(23)
x <- data.frame(q = rnorm(99,0,5)^2,
                r = rnorm(99,0,5)^2,
                s = rnorm(99,10,10)^2)
cond_cdf(x, 'pairs')
joint_cdf(x, 'pairs')
cond_cdf(x, 'rgl')
joint_cdf(x, 'rgl')

phytomosaic/vuln documentation built on Sept. 21, 2019, 8:23 a.m.