| as.BDataDensities | R Documentation |
This represents BayesSpace data by a list of density functions, i.e. one density (with respect to the reference measure) per observation. Use this representation to inspect or plot the distributions as densities; for computation (PCA, distances) convert further to splines with [as.BDataSplines].
as.BDataDensities(x, ...)
## S3 method for class 'BDataDensities'
as.BDataDensities(x, ...)
## S3 method for class 'BDataSplines'
as.BDataDensities(x, ..., basis = getBayesSpaceBasis(x))
## S3 method for class 'BDataLogDensities'
as.BDataDensities(x, ..., basis = getBayesSpaceBasis(x))
## S3 method for class 'BDataPDFs'
as.BDataDensities(x, ..., basis = getBayesSpaceBasis(x))
## S3 method for class 'BDataLogPDFs'
as.BDataDensities(x, ..., basis = getBayesSpaceBasis(x))
## S3 method for class 'BDataHistograms'
as.BDataDensities(
x,
...,
background = 0,
basis = getBayesSpaceBasis(x),
dmu = getPDF(getReferenceMeasure(basis))
)
## S3 method for class 'BDataSamples'
as.BDataDensities(
x,
...,
method = c("Fisher", "kde"),
basis = getBayesSpaceBasis(x)
)
x |
the data to be converted |
... |
generic arguments potentially used by methods, e.g. to define a method of computation. |
basis |
the BayesSpaceBasis to be assigned to the object. Necessary if non can be infered from the information presented to the function. |
background |
the valued for the density outside of the interval. |
dmu |
the Lebesgue density of the reference measure. |
method |
a character string defining the method of computation of the density form the data. "Fisher" stands for Fisher scoring and tries to fit an exponential family model given by the subspace of the BayesSpace. It might fail for certain datasets. See [FisherScoringEstimation] for further method parameters. "kde" stands for kernel density estimation. See [kdeDensity] for further possible parameters. |
A BDataDensities object (densities w.r.t. the reference measure).
as.BDataDensities(BDataDensities): method for the class itself das nothing
as.BDataDensities(BDataSplines): constructs the projected functions
as.BDataDensities(BDataLogDensities): calls [BDataDensities.BDataLogDensities]
as.BDataDensities(BDataPDFs): divides PDFs by PDF of reference measure
as.BDataDensities(BDataLogPDFs): divides PDFs by PDF of reference measure
as.BDataDensities(BDataHistograms): method for histograms (TODO: Uses a
very crude heuristic to estimate the log density)
as.BDataDensities(BDataSamples): constructs a density from the samples
[.DensityFromHist]
Other BayesSpaceConverters:
as.BDataDensityHistograms(),
as.BDataFrequencyHistograms(),
as.BDataHistograms(),
as.BDataLogDensities(),
as.BDataLogPDFs(),
as.BDataPDFs(),
as.BDataSamples(),
as.BDataSplines(),
idt.BData(),
toHistogram()
X = BDataLogDensities(list(sin,cos),basis=B2Unif01Basis5)
as.BDataDensities(X)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.