| B2GaussianDistribution | R Documentation |
A Gaussian Process distribution for probabilities
Simulate a Gaussian Distribution on B2
B2GaussianDistribution(
mean = BDataLogDensities(list(function(x) rep(0, length(x))), basis = B2Unif01Basis7),
var = varKernel(function(x, y) exp(-abs(outer(x, y, "-"))), basis =
getBayesSpaceBasis(mean)),
nEval = 513
)
## S3 method for class 'B2GaussianDistribution'
simulate(object, nsim = 1, seed = NULL, ..., nEval = object$nEval)
mean |
something covertable to a single BDataLogDensity, providing the Bayes space expectation of the distribution, as well as BayesSpace and Support. Currently only finite continuous supports are possible. You might want to simulate on B2Unif01 and transform for other Transformed spaces. |
var |
a function of two arguments providing the covariance operator |
nEval |
the number of equispaced discretization points used on the interval. |
object |
the B2GaussianDistribution object |
nsim |
the number of simulations to be computed |
seed |
the optional seed, if used it will be reported as a seed attribution of the result (use with care) |
... |
unused arguments for generic use |
B2GaussianDistribution: a B2GaussianDistribution object which can be simulated with, simulate: BDataLogDensities-Object with nsim cases with the same BayesSpace and BayesSpaceBasis as the mean.
simulate(B2GaussianDistribution): Simulaton method
[
[stats::simulate]
m = BDataPDFs(list(dunif),basis=B2Unif01Basis7)
G1 = B2GaussianDistribution(m,function(x,y) exp(-(4*abs(x-y)^1.7)))
plot(simulate(G1,10,seed=47),col=2:11)
GD = B2GaussianDistribution(mean=BDataPDFs(\(x)x,basis=B2Unif01Basis5),
var=\(x,y) exp(-abs(x-y)))
plot(simulate(GD,5))
GD = B2GaussianDistribution(mean=BDataPDFs(\(x) dnorm(x),basis=B2N01Basis5),
var=\(x,y) exp(-abs(x-y)))
plot(as.BDataPDFs(simulate(GD,5)))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.