mlePoissonTweedie: Maximum likelihood estimation of the Poisson-Tweedie...

Description Usage Arguments Details Value References See Also Examples

Description

Maximum likelihood estimation of the Poisson-Tweedie parameters using L-BFGS-B quasi-Newton method.

Usage

1
2
3
mlePoissonTweedie(x, a, D.ini, a.ini, maxit = 100, loglik=TRUE,
maxCount=20000, w = NULL, ...)
getParam(object)

Arguments

x

numeric vector containing the read counts.

a

numeric scalar smaller than 1, if specified the PT shape parameter will be fixed.

D.ini

numeric positive scalar giving the initial value for the dispersion.

a.ini

numeric scalar smaller than 1 giving the initial value for the shape parameter (ignored if 'a' is specified).

maxit

numeric scalar providing the maximum number of 'L-BFGS-B' iterations to be performed (default is '100').

loglik

is log-likelihood computed? The default is TRUE

object

an object of class 'mlePT'.

maxCount

if max(x) > maxCount, then moment method is used to estimate model parameters to reduce computation time. The default is 20000.

w

vector of weights with length equal to the lenght of 'x'.

...

additional arguments to be passed to the 'optim' 'control' options.

Details

The L-BFGS-B quasi-Newton method is used to calculate iteratively the maximum likelihood estimates of the three Poisson-Tweedie parameters. If 'a' argument is specified, this parameter will be fixed and the method will only estimate the other two.

Value

An object of class 'mlePT' containing the following information:

par: numeric vector giving the estimated mean ('mu'), dispersion ('D') and shape parameter 'a'.

se: numeric vector containing the standard errors of the estimated parameters 'mu', 'D' and 'a'.

loglik: numeric scalar providing the value of the loglikelihod for the estimated parameters.

iter: numeric scalar giving the number of performed iterations.

paramZhu: numeric vector giving the values of the estimated parameters in the Zhu parameterization 'a', 'b' and 'c'.

paramHou: numeric vector giving the values of the estimated parameters in the Hougaard parameterization 'alpha', 'delta' and 'theta'.

skewness: numeric scalar providing the estimate of the skewness given the estimated parameters.

x: numeric vector containing the count data introduced as the 'x' argument by the user.

convergence: A character string giving any additional information returned by the optimizer, or 'NULL'.

References

Esnaola M, Puig P, Gonzalez D, Castelo R and Gonzalez JR (2013). A flexible count data model to fit the wide diversity of expression profiles arising from extensively replicated RNA-seq experiments. BMC Bioinformatics 14: 254

A.H. El-Shaarawi, R. Zhu, H. Joe (2010). Modelling species abundance using the Poisson-Tweedie family. Environmetrics 22, pages 152-164.

P. Hougaard, M.L. Ting Lee, and G.A. Whitmore (1997). Analysis of overdispersed count data by mixtures of poisson variables and poisson processes. Biometrics 53, pages 1225-1238.

See Also

testShapePT print.mlePT

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
# Generate 500 random counts following a Poisson Inverse Gaussian
# distribution with mean = 20 and dispersion = 5
randomCounts <- rPT(n = 500, mu = 20, D = 5, a = 0.5)

# Estimate all three parameters
res1 <- mlePoissonTweedie(x = randomCounts, a.ini = 0, D.ini
= 10)
res1
getParam(res1)

#Fix 'a = 0.5' and estimate the other two parameters
res2 <- mlePoissonTweedie(x = randomCounts, a = 0.5, D.ini
= 10)
res2
getParam(res2)

Example output

Poisson-Tweedie parameter estimates (MLE)

   estimate  s.e.
mu    19.91 0.456
D      5.23 0.412
a      0.54 0.091
Skewness: 1.32

 Zhu parameterization 
    a     b     c 
0.538 7.572 0.902 

 Hougaard parameterization 
alpha delta theta 
0.538 7.162 0.109 

 log-likelihood: -1807.421
 number of iterations: 9
        mu          D          a 
19.9120000  5.2306312  0.5384602 

Poisson-Tweedie parameter estimates (MLE)

   estimate s.e.
mu     19.9 0.45
D       5.2 0.36
a       0.5   NA
Skewness: 1.25

 Zhu parameterization 
    a     b     c 
0.500 7.303 0.893 

 Hougaard parameterization 
alpha delta theta 
0.500 6.901 0.120 

 log-likelihood: -1807.501
 number of iterations: 6
       mu         D         a 
19.912000  5.163067  0.500000 

tweeDEseq documentation built on Nov. 8, 2020, 5:59 p.m.