simulate.BData: Simulate from the distribution described by the BData objects

View source: R/simulations.R

simulate.BDataR Documentation

Simulate from the distribution described by the BData objects

Description

Simulate from the distribution described by the BData objects

Usage

## S3 method for class 'BData'
simulate(
  object,
  nsim = 1L,
  seed = NULL,
  ...,
  returnBDataSamples = numberOfCases(object) > 1
)

Arguments

object

a dataset of distributions from a BayesSpace

nsim

number of simulations

seed

the seed to be used. If seed is given the resulting object has a seed attribute, with the seed given (use with care).

...

futher generic parameters e.g. for the method of simulation used.

returnBDataSamples

a boolean, if returnBDataSamples==FALSE 'object' may only contain 1 distribution and the simulation of that distribution is returned directly. If TRUE the simulation is done for each of them and the results is returned as BDataSamples.

Value

(Planned, once implemented:) A BDataSample object with each entry nsim simulations and one simulation for each distribution in the BData object. Currently the function always throws an error.

Note

**Not yet implemented.** Calling this method currently stops with an error. It is registered so that 'simulate()' on a 'BData' object gives an informative message rather than a method-dispatch failure. The documented parameters and return value describe the planned interface.


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