#a simple example
FVDDP = initialize(theta = 1, sampling.f = function(x) rpois(x, 3),
density.f = function(x) dpois(x, 3), atomic = TRUE)
FVDDP = update(FVDDP, c(4,5))
print(FVDDP)
#in case there are no data
FVDDP=initialize(theta = 3, function(x) rnorm(x, -1, 3),
function(x) dnorm(x, -1, 3), atomic = FALSE)
print(FVDDP)
Run the code above in your browser using DataLab