Description Usage Arguments Value Author(s) See Also Examples
Create an object of class "Bbdpars"
which may be used
as an argument of the simulate()
function.
1 | makeBbdpars(m, s, size, ndata)
|
m |
Numeric scalar between 0 and 1. May be interpreted as a “success probability”. |
s |
Numeric scalar, greater than 0. The overdispersion parameter
of the beta binomial distribution. Note that if overdispersion
is defined to equal the ratio of the variance of the data to
the corresponding “binomial variance” (i.e.
the actual variance over |
size |
Integer scalar specifying the upper limit of the “support”
of the beta binomial distribution under consideration. The support
is the set of integers |
ndata |
Integer vector specifying the lengths of the data sets to
be simulated. If it is of length less than the |
An object of class "Bbdpars"
which is a list with components
m
, s
, size
and ndata
. The entries
of this list are simply the corresponding function arguments.
Rolf Turner r.turner@auckland.ac.nz
1 2 3 4 5 6 7 8 9 10 11 12 13 | obj1 <- makeBbdpars(m=0.35,s=0.3,size=20,ndata=500)
obj2 <- makeBbdpars(m=0.85,s=1.7,size=20,ndata=30*(1:10))
## Not run:
sdat1 <- simulate(obj1,nsim=100)
sdat2 <- simulate(obj2,nsim=100)
## End(Not run)
sdat3 <- simulate(obj2,nsim=10)
## Not run:
sdat4 <- simulate(obj2,nsim=100,ndata=100*(2:6)) # The ndata component of
# obj2 is ignored.
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.