mvar.BData: Compute the metric variance

mvar.BDataR Documentation

Compute the metric variance

Description

The metric variance is the expected squared distance from the mean in the metric of the enclosing space. By construction the metric variance computed from a spline representation should be smaller than metrix variances computed on functional data, because the spline captures only a part of the variance.

Usage

## S3 method for class 'BData'
mvar(x, ..., meanx = mean(x), method = "classical")

## S3 method for class 'BDataSplines'
mvar(x, ..., method = c("classical", "mcd", "mve"), meanx = mean(x, method))

## S3 method for class 'BData'
msd(x, ...)

Arguments

x

some BData dataset.

...

further parameters for the methods to compute it (expectation)

meanx

an external mean estimate

method

the method of variance estimation

Value

a positive real number representing the metric variance

Functions

  • mvar(BDataSplines): a specialized method for BDataSpline, which does not require integration.

  • msd(BData): compute the metric standard deviation, proportional to the square root of the metric variance

Examples

data(DTD)
Xpdf    = BDataPDFs(DTD$shapePDF,basis=B2Unif01Basis5)
Xsplines= as.BDataSplines(Xpdf)
mvar(Xsplines)
 mvar(Xsplines,method="mcd")
mvar(as.BDataDensities(Xpdf))
mvar(as.BDataLogDensities(Xpdf))
mvar(as.BDataLogPDFs(Xpdf))
mvar(Xpdf)


DistributionalDDA documentation built on Oct. 20, 2026, 5:06 p.m.