varDb {dbd}R Documentation

Variance of a db distribution.

Description

Calculate the variance of a random variable having a db distribution.

Usage

varDb(ao,...)
## S3 method for class 'mleDb'
varDb(ao,...)
## Default S3 method:
varDb(ao, beta, ntop, zeta=FALSE,...)

Arguments

ao

For the "mleDb" method this argument is an object of class "mleDb" as returned by mleDb(). For the default method it is a numeric scalar playing the role of alpha (see ddb()).

beta

See ddb().

ntop

See ddb().

zeta

See ddb().

...

Not used.

Details

For the "mleDb" method, the single argument should really be called (something like) “object” and for the default method the first argument should be called alpha. However the argument lists must satisfy the restrictions that “A method must have all the arguments of the generic, including ... if the generic does.” and “A method must have arguments in exactly the same order as the generic.

For the "mleDb" method, the values of alpha and beta are obtained from ao, and ntop, and zeta are extracted from the attributes of ao.

The variance of a db distribution is theoretically intractable but is readily calculable numerically as

\sum (x - \mu)^2 \times \Pr(X=x)

, where \mu is the expected value of the given distribution.

Value

Numeric scalar equal to the variance of a db distributed random variable with the given parameters.

Author(s)

Rolf Turner r.turner@auckland.ac.nz

See Also

ddb() expValDb()

Examples

   varDb(3,4,15)
   varDb(3,4,15,TRUE)
   X   <- hmm.discnp::Downloads
   fit <- mleDb(X,ntop=15,zeta=TRUE)
   varDb(fit)

[Package dbd version 0.0-22 Index]