ADMB Documentation  11.5.3197
 All Classes Files Functions Variables Typedefs Friends Defines
Functions | Variables
qfclib.h File Reference
#include <math.h>
#include <admodel.h>
#include <df1b2fun.h>
#include <adrndeff.h>

Go to the source code of this file.

Functions

dvar_vector boundp (const dvar_vector &x, const double fmin, const double fmax, const dvariable &fpen)
 overloading bounded functions for vector, ADMB has builtin boundp, but not for vector type

df1b2vector boundp (const df1b2vector &x, const double fmin, const double fmax, const df1b2variable &fpen)
bool doubleEqual (double nVal1, double nVal2, int nPrecision)
 determine if two double values are equal within some precision
dmatrix findValFromFile (adstring filename, adstring varName, int numVals)
 find the number of values(numVals) for one specific variable(varName) from an admb output file
dvar_vector invLogitProp (const dvar_vector &p)
 reverse function for LogitProp
df1b2vector invLogitProp (const df1b2vector &p)
df1b2vector log_comb (const df1b2vector &n, const df1b2vector &x)
 overloading function for log_comb(n choose x) for randome effect, used in nllBinomial below, ADMB built in function log_comb() not for vector type in RE
df1b2vector log_comb (const df1b2vector &n, const dvector &x)
df1b2vector log_comb (const dvector &n, const df1b2vector &x)
dvar_vector logitProp (const dvar_vector &a)
 constrain probability vector as 1 and I forgot who create this first, may give credit to Punt., let logit(p)=log(p/(1-p))=a, so p=exp(a)/(1+exp(a)) ~[0,1]
df1b2vector logitProp (const df1b2vector &a)
dvector matrix2vector (const dmatrix &input, int byrow)
 convert the matrix as a vector eithter by row=1(default) or by column=0,
dvar_vector matrix2vector (const dvar_matrix &input, int byrow)
 convert the matrix as a vector eithter by row=1(default) or by column=0, overloading function
df1b2vector matrix2vector (const df1b2matrix &input, int byrow)
 convert the matrix as a vector eithter by row=1(default) or by column=0, overloading function
dvariable mf_upper_bound2 (const dvariable &x, const double fmax, dvariable &fpen)
 constrain parameter with upper threshold, if return bigger than it, then with penalty ADMB have built in function mf_upper_bound(), which have more constrain on the values higher than the bounds with bigger penalty than this version
df1b2variable mf_upper_bound2 (const df1b2variable &x, const double fmax, df1b2variable &fpen)
double nllBeta (const double x, const double a, const double b)
 nll for beta for one sample $ -\ln(\Gamma(a+b)) +\ln(\Gamma(a)) + \ln(\Gamma(b))-(a-1)\ln(x)-(b-1)\ln(1-x) $
dvariable nllBeta (const dvariable &x, const double a, const double b)
dvariable nllBeta (const double x, const dvariable &a, const dvariable &b)
dvariable nllBeta (const dvariable &x, const dvariable &a, const double b)
dvariable nllBeta (const dvariable &x, const double a, const dvariable &b)
dvariable nllBeta (const dvariable &x, const dvariable &a, const dvariable &b)
df1b2variable nllBeta (const df1b2variable &x, const double a, const double b)
 nll for beta for one sample for random effect $ -\ln(\Gamma(a+b)) +\ln(\Gamma(a)) + \ln(\Gamma(b))-(a-1)\ln(x)-(b-1)\ln(1-x) $
df1b2variable nllBeta (const df1b2variable &x, const df1b2variable &a, const double b)
df1b2variable nllBeta (const df1b2variable &x, const double a, const df1b2variable &b)
df1b2variable nllBeta (const double x, const df1b2variable &a, const df1b2variable &b)
df1b2variable nllBeta (const df1b2variable &x, const df1b2variable &a, const df1b2variable &b)
dvariable nllBeta (const dvar_vector &x, const double a, const double b)
 nll for beta for many samples $ -n\ln(\Gamma(a+b)) +n\ln(\Gamma(a)) + n\ln(\Gamma(b))-(a-1)\sum(\ln(x)) -(b-1)\sum(\ln(1-x)) $
dvariable nllBeta (const dvector &x, const dvariable &a, const dvariable &b)
dvariable nllBeta (const dvar_vector &x, const dvariable &a, const dvariable &b)
df1b2variable nllBeta (const df1b2vector &x, const double a, const double b)
 nll for beta for many samples for random effect $ -n\ln(\Gamma(a+b)) +n\ln(\Gamma(a)) + n\ln(\Gamma(b))-(a-1)\sum(\ln(x)) -(b-1)\sum(\ln(1-x)) $
df1b2variable nllBeta (const dvector &x, const df1b2variable &a, const df1b2variable &b)
df1b2variable nllBeta (const df1b2vector &x, const df1b2variable &a, const df1b2variable &b)
double nllBinomial (const double x, const double n, const double p)
 nll for binomial for one sample $ \ln(x!) + \ln((n-x)!) -\ln(n!) - x \ln(p) - (n-x) \ln(1-p) $
dvariable nllBinomial (const dvariable &x, const double n, const double p)
dvariable nllBinomial (const double x, const dvariable &n, const dvariable &p)
dvariable nllBinomial (const dvariable &x, const dvariable &n, const dvariable &p)
df1b2variable nllBinomial (const df1b2variable &x, const double n, const double p)
 nll for binomial for one sample for random effect $ \ln(x!) + \ln((n-x)!) -\ln(n!) - x \ln(p) - (n-x) \ln(1-p) $
df1b2variable nllBinomial (const double x, const df1b2variable &n, const df1b2variable &p)
df1b2variable nllBinomial (const df1b2variable &x, const df1b2variable &n, const df1b2variable &p)
dvariable nllBinomial (const dvar_vector &x, const dvector &n, const double p)
 nll for binomial for many samples $ -\sum\ln{{n_{i}}\choose{x_{i}}}- \sum(x_{i})\ln(p)- \sum(n_{i}-x_{i})\ln(1-p) $
dvariable nllBinomial (const dvector &x, const dvar_vector &n, const dvariable &p)
dvariable nllBinomial (const dvar_vector &x, const dvar_vector &n, const dvariable &p)
df1b2variable nllBinomial (const dvector &x, const df1b2vector &n, const df1b2variable &p)
 nll for binomial for many samples for random effect $ -\sum\ln{{n_{i}}\choose{x_{i}}}- \sum(x_{i})\ln(p)- \sum(n_{i}-x_{i})\ln(1-p) $
df1b2variable nllBinomial (const df1b2vector &x, const dvector &n, const double p)
df1b2variable nllBinomial (const df1b2vector &x, const df1b2vector &n, const df1b2variable &p)
double nllDirichlet (const dvector &p, const dvector &shape)
 nll for dirichlet for one sample $ -\ln\Gamma(\sum_{i}(\alpha_{i})) -\sum_{i}(\ln(\Gamma(\alpha_{i}))) +\sum_{i}((\alpha_{i}-1)\ln(p_{i})) $
dvariable nllDirichlet (const dvar_vector &p, const dvector &shape)
dvariable nllDirichlet (const dvector &p, const dvar_vector &shape)
dvariable nllDirichlet (const dvar_vector &p, const dvar_vector &shape)
df1b2variable nllDirichlet (const df1b2vector &p, const dvector &shape)
 nll for dirichlet for one sample for random effect $ -\ln\Gamma(\sum_{i}(\alpha_{i})) -\sum_{i}(\ln(\Gamma(\alpha_{i}))) +\sum_{i}((\alpha_{i}-1)\ln(p_{i})) $
df1b2variable nllDirichlet (const dvector &p, const df1b2vector &shape)
df1b2variable nllDirichlet (const df1b2vector &p, const df1b2vector &shape)
double nllGamma (const double &x, const double a, const double b)
 nll for gamma for one sample Gamma(a,b) similar to log_gamma_density(r,mu) in admb, in which a=r, b=mu $ -a \ln(b) + \ln(\Gamma(a)) - (a-1)\ln(x)+ bx $
dvariable nllGamma (const dvariable &x, const double a, const double b)
dvariable nllGamma (const double x, const dvariable &a, const dvariable &b)
dvariable nllGamma (const dvariable &x, const dvariable &a, const double b)
dvariable nllGamma (const dvariable &x, const double a, const dvariable &b)
dvariable nllGamma (const dvariable &x, const dvariable &a, const dvariable &b)
df1b2variable nllGamma (const df1b2variable &x, const double a, const double b)
 nll for gamma for one sample for random effect Gamma(a,b) similar to log_gamma_density(r,mu) in admb, in which a=r, b=mu $ -a \ln(b) + \ln(\Gamma(a)) - (a-1)\ln(x)+ bx $
df1b2variable nllGamma (const double x, const df1b2variable &a, const df1b2variable &b)
df1b2variable nllGamma (const df1b2variable &x, const df1b2variable &a, const double b)
df1b2variable nllGamma (const df1b2variable &x, const double a, const df1b2variable &b)
df1b2variable nllGamma (const df1b2variable &x, const df1b2variable &a, const df1b2variable &b)
double nllGamma (const dvector &x, const double a, const double b)
 nll for gamma for many samples $ -na\ln(b) + n\ln(\Gamma(a)) - (a-1)\sum(\ln(x))+ b\sum(x) $
dvariable nllGamma (const dvar_vector &x, const double a, const double b)
dvariable nllGamma (const dvector &x, const dvariable &a, const dvariable &b)
dvariable nllGamma (const dvar_vector &x, const dvariable &a, const dvariable &b)
df1b2variable nllGamma (const df1b2vector &x, const double a, const double b)
 nll for gamma for many samples for random effect $ -na\ln(b) + n\ln(\Gamma(a)) - (a-1)\sum(\ln(x))+ b\sum(x) $
df1b2variable nllGamma (const dvector &x, const df1b2variable &a, const df1b2variable &b)
df1b2variable nllGamma (const df1b2vector &x, const df1b2variable &a, const df1b2variable &b)
double nllInverseGamma (const double x, const double a, const double b)
 nll for inverse gamma for one sample $ -a \ln(b) + \ln(\Gamma(a)) + (a+1)\ln(x)+ b/x $
dvariable nllInverseGamma (const dvariable &x, const double a, const double b)
dvariable nllInverseGamma (const double x, const dvariable &a, const dvariable &b)
dvariable nllInverseGamma (const dvariable &x, const dvariable &a, const dvariable &b)
df1b2variable nllInverseGamma (const df1b2variable &x, const double a, const double b)
 nll for inverse gamma for one sample for random effect $ -a \ln(b) + \ln(\Gamma(a)) + (a+1)\ln(x)+ b/x $
df1b2variable nllInverseGamma (const double x, const df1b2variable &a, const df1b2variable &b)
df1b2variable nllInverseGamma (const df1b2variable &x, const df1b2variable &a, const double b)
df1b2variable nllInverseGamma (const df1b2variable &x, const double a, const df1b2variable &b)
df1b2variable nllInverseGamma (const df1b2variable &x, const df1b2variable &a, const df1b2variable &b)
dvariable nllInverseGamma (const dvar_vector &x, const double a, const double b)
 nll for inverse gamma for many samples $ -na \ln(b) + n\ln(\Gamma(a)) + (a+1)\sum(\ln(x))+ b/\sum(x) $
dvariable nllInverseGamma (const dvector &x, const dvariable &a, const dvariable &b)
dvariable nllInverseGamma (const dvar_vector &x, const dvariable &a, const dvariable &b)
df1b2variable nllInverseGamma (const dvector &x, const df1b2variable &a, const df1b2variable &b)
 nll for inverse gamma for many samples for random effect $ -na \ln(b) + n\ln(\Gamma(a)) + (a+1)\sum(\ln(x))+ b/\sum(x) $
df1b2variable nllInverseGamma (const df1b2vector &x, const double a, const double b)
df1b2variable nllInverseGamma (const df1b2vector &x, const df1b2variable &a, const df1b2variable &b)
double nllLognormal (const double x, const double mu, const double sigma)
 nll for lognormal for one sample $ 0.5\ln(2 \pi) + \ln(x) +\ln(\sigma) + 0.5(\frac{\ln(x)-\mu}{\sigma})^2 $
dvariable nllLognormal (const dvariable &x, const double mu, const double sigma)
dvariable nllLognormal (const double x, const dvariable &mu, const dvariable &sigma)
dvariable nllLognormal (const dvariable &x, const dvariable &mu, const double sigma)
dvariable nllLognormal (const dvariable &x, const double mu, const dvariable &sigma)
dvariable nllLognormal (const dvariable &x, const dvariable &mu, const dvariable &sigma)
df1b2variable nllLognormal (const df1b2variable &x, const double mu, const double sigma)
 nll for lognormal for one sample for random effect $ 0.5\ln(2 \pi) + \ln(x) +\ln(\sigma) + 0.5(\frac{\ln(x)-\mu}{\sigma})^2 $
df1b2variable nllLognormal (const double x, const df1b2variable &mu, const df1b2variable &sigma)
df1b2variable nllLognormal (const df1b2variable &x, const df1b2variable &mu, const double sigma)
df1b2variable nllLognormal (const df1b2variable &x, const double mu, const df1b2variable &sigma)
df1b2variable nllLognormal (const df1b2variable &x, const df1b2variable &mu, const df1b2variable &sigma)
dvariable nllLognormal (const dvar_vector &x, const double mu, const double sigma)
 nll for lognormal for many samples $ 0.5n\ln(2 \pi) + \sum\ln(x) +n\ln(\sigma) + 0.5\sum(\frac{\ln(x)-\mu}{\sigma})^2 $
dvariable nllLognormal (const dvector &x, const dvariable &mu, const dvariable &sigma)
dvariable nllLognormal (const dvar_vector &x, const dvariable &mu, const dvariable &sigma)
df1b2variable nllLognormal (const df1b2vector &x, const double mu, const double sigma)
 nll for lognormal for many samples for random effect $ 0.5n\ln(2 \pi) + \sum\ln(x) +n\ln(\sigma) + 0.5\sum(\frac{\ln(x)-\mu}{\sigma})^2 $
df1b2variable nllLognormal (const dvector &x, const df1b2variable &mu, const df1b2variable &sigma)
df1b2variable nllLognormal (const df1b2vector &x, const df1b2variable &mu, const df1b2variable &sigma)
dvariable nllLognormal (const dvar_vector &x, const dvector &mu, const double sigma)
 nll for lognormal for many samples, each has its mean $ 0.5n\ln(2 \pi) + \sum\ln(x_{i}) +n\ln(\sigma) + 0.5\sum(\frac{\ln(x_{i})-\mu_{i}}{\sigma})^2 $
dvariable nllLognormal (const dvector &x, const dvar_vector &mu, const dvariable &sigma)
dvariable nllLognormal (const dvar_vector &x, const dvar_vector &mu, const dvariable &sigma)
df1b2variable nllLognormal (const df1b2vector &x, const dvector &mu, const double sigma)
 nll for lognormal for many samples, each has its mean, for random effect $ 0.5n\ln(2 \pi) + \sum\ln(x_{i}) +n\ln(\sigma) + 0.5\sum(\frac{\ln(x_{i})-\mu_{i}}{\sigma})^2 $
df1b2variable nllLognormal (const dvector &x, const df1b2vector &mu, const df1b2variable &sigma)
df1b2variable nllLognormal (const df1b2vector &x, const df1b2vector &mu, const df1b2variable &sigma)
dvariable nllLognormal2 (const double x, const dvariable &mu, const dvariable &tau)
 nll for lognormal(mu,tau) for one sample $ 0.5\ln(2 \pi) + \ln(x) -0.5\ln(\tau) + 0.5\tau(\ln(x)-\mu)^2 $
dvariable nllLognormal2 (const dvariable &x, const double mu, const double tau)
dvariable nllLognormal2 (const dvariable &x, const dvariable &mu, const dvariable &tau)
df1b2variable nllLognormal2 (const df1b2variable x, const double mu, const double tau)
 nll for lognormal(mu,tau) for one sample for random effect $ 0.5\ln(2 \pi) + \ln(x) -0.5\ln(\tau) + 0.5\tau(\ln(x)-\mu)^2 $
df1b2variable nllLognormal2 (const double x, const df1b2variable &mu, const df1b2variable &tau)
df1b2variable nllLognormal2 (const df1b2variable x, const df1b2variable &mu, const double tau)
df1b2variable nllLognormal2 (const df1b2variable x, const double mu, const df1b2variable &tau)
df1b2variable nllLognormal2 (const df1b2variable x, const df1b2variable &mu, const df1b2variable &tau)
dvariable nllLognormal2 (const dvar_vector &x, const double mu, const double tau)
 nll for lognormal(mu,tau) for many samples $ 0.5n\ln(2 \pi) + \sum\ln(x) -0.5n\ln(\tau) + 0.5\tau\sum(\ln(x)-\mu)^2 $
dvariable nllLognormal2 (const dvector &x, const dvariable &mu, const dvariable &tau)
dvariable nllLognormal2 (const dvar_vector &x, const dvariable &mu, const dvariable &tau)
df1b2variable nllLognormal2 (const dvector &x, const df1b2variable &mu, const df1b2variable &tau)
 nll for lognormal(mu,tau) for many samples for random effect $ 0.5n\ln(2 \pi) + \sum\ln(x) -0.5n\ln(\tau) + 0.5\tau\sum(\ln(x)-\mu)^2 $
df1b2variable nllLognormal2 (const df1b2vector &x, const double mu, const double tau)
df1b2variable nllLognormal2 (const df1b2vector &x, const df1b2variable &mu, const double tau)
df1b2variable nllLognormal2 (const df1b2vector &x, const double mu, const df1b2variable &tau)
df1b2variable nllLognormal2 (const df1b2vector &x, const df1b2variable &mu, const df1b2variable &tau)
dvariable nllLognormal2 (const dvar_vector &x, const dvector &mu, const double tau)
 nll for lognormal(mu,tau) for many samples, each has its mean $ 0.5n\ln(2 \pi) + \sum\ln(x_{i}) -0.5n\ln(\tau) + 0.5\tau\sum(\ln(x_{i})-\mu_{i})^2 $
dvariable nllLognormal2 (const dvector &x, const dvar_vector &mu, const dvariable &tau)
dvariable nllLognormal2 (const dvar_vector &x, const dvar_vector &mu, const dvariable &tau)
df1b2variable nllLognormal2 (const df1b2vector &x, const dvector &mu, const double tau)
 nll for lognormal(mu,tau) for many samples, each has its mean, overload for random effect, $ 0.5n\ln(2 \pi) + \sum\ln(x_{i}) -0.5n\ln(\tau) + 0.5\tau\sum(\ln(x_{i})-\mu_{i})^2 $
df1b2variable nllLognormal2 (const dvector &x, const df1b2vector &mu, const df1b2variable &tau)
df1b2variable nllLognormal2 (const df1b2vector &x, const df1b2vector &mu, const df1b2variable &tau)
double nllMultiNomial (const dvector &obsN, const dvector &p)
 nll for Multinomial for one sample $ -\sum_{i}(n_{i}\ln(p_{i})) -\ln((\sum_{i}n_{i})!) +\sum_{i}(\ln(n_{i}!)) $
dvariable nllMultiNomial (const dvector &obsN, const dvar_vector &p)
dvariable nllMultiNomial (const dvar_vector &obsN, const dvector &p)
dvariable nllMultiNomial (const dvar_vector &obsN, const dvar_vector &p)
df1b2variable nllMultiNomial (const df1b2vector &obsN, const dvector &p)
 nll for Multinomial for one sample for random effect $ -\sum_{i}(n_{i}\ln(p_{i})) -\ln((\sum_{i}n_{i})!) +\sum_{i}(\ln(n_{i}!)) $
df1b2variable nllMultiNomial (const dvector &obsN, const df1b2vector &p)
df1b2variable nllMultiNomial (const df1b2vector &obsN, const df1b2vector &p)
double nllNegativeBinomial (const double obs, const double m, const double s)
 nll for negative binomial N(m,s) for one sample, admb built in log_negbinomial_density(obs,mu,tau), in which tau=1.
dvariable nllNegativeBinomial (const dvariable &obs, const double m, const double s)
dvariable nllNegativeBinomial (const double obs, const dvariable &m, const dvariable &s)
dvariable nllNegativeBinomial (const dvariable &obs, const dvariable &m, const double s)
dvariable nllNegativeBinomial (const dvariable &obs, const double m, const dvariable &s)
dvariable nllNegativeBinomial (const dvariable &obs, const dvariable &m, const dvariable &s)
df1b2variable nllNegativeBinomial (const df1b2variable &obs, const double m, const double s)
 nll for negative binomial N(m,s) for one sample,overload for random effect, admb built in log_negbinomial_density(obs,mu,tau), in which tau=1.
df1b2variable nllNegativeBinomial (const double obs, const df1b2variable &m, const df1b2variable &s)
df1b2variable nllNegativeBinomial (const df1b2variable &obs, const df1b2variable &m, const double s)
df1b2variable nllNegativeBinomial (const df1b2variable &obs, const double m, const df1b2variable &s)
df1b2variable nllNegativeBinomial (const df1b2variable &obs, const df1b2variable &m, const df1b2variable &s)
dvariable nllNegativeBinomial (const dvector &obs, const dvariable &m, const dvariable &s)
 nll for negative binomial N(m,s) for many samples, admb built in log_negbinomial_density(obs,mu,tau), in which tau=1.
dvariable nllNegativeBinomial (const dvar_vector &obs, const double m, const double s)
dvariable nllNegativeBinomial (const dvar_vector &obs, const dvariable &m, const dvariable &s)
df1b2variable nllNegativeBinomial (const df1b2vector &obs, const double m, const double s)
 nll for negative binomial N(m,s) for many samples, overload for random effect, admb built in log_negbinomial_density(obs,mu,tau), in which tau=1.
df1b2variable nllNegativeBinomial (const dvector &obs, const df1b2variable &m, const df1b2variable &s)
df1b2variable nllNegativeBinomial (const df1b2vector &obs, const df1b2variable &m, const df1b2variable &s)
double nllNegativeBinomial2 (const double obs, const double m, const double tau)
 nll for negative binomial N(mu,tau) for one sample, admb built in log_negbinomial_density(obs,mu,tau), in which tau=1.
dvariable nllNegativeBinomial2 (const double obs, const dvariable &m, const dvariable &tau)
dvariable nllNegativeBinomial2 (const dvariable &obs, const double m, const double tau)
dvariable nllNegativeBinomial2 (const dvariable &obs, const dvariable &m, const double tau)
dvariable nllNegativeBinomial2 (const dvariable &obs, const double m, const dvariable &tau)
dvariable nllNegativeBinomial2 (const dvariable &obs, const dvariable &m, const dvariable &tau)
df1b2variable nllNegativeBinomial2 (const df1b2variable &obs, const double m, const double tau)
 nll for negative binomial N(mu,tau) for one sample,overload for random effect admb built in log_negbinomial_density(obs,mu,tau), in which tau=1.
df1b2variable nllNegativeBinomial2 (const double obs, const df1b2variable &m, const df1b2variable &tau)
df1b2variable nllNegativeBinomial2 (const df1b2variable &obs, const df1b2variable &m, const df1b2variable &tau)
double nllNormal (const double x, const double mu, const double sigma)
 nll for normal for one sample $ 0.5\ln(2 \pi) + \ln(\sigma) + 0.5(\frac{x-\mu}{\sigma})^2 $
dvariable nllNormal (const dvariable &x, const double mu, const double sigma)
dvariable nllNormal (const double x, const dvariable &mu, const dvariable &sigma)
dvariable nllNormal (const dvariable &x, const dvariable &mu, const double sigma)
dvariable nllNormal (const dvariable &x, const double mu, const dvariable &sigma)
dvariable nllNormal (const dvariable &x, const dvariable &mu, const dvariable &sigma)
df1b2variable nllNormal (const df1b2variable &x, const double mu, const double sigma)
 nll for normal for one sample for random effect $ 0.5\ln(2 \pi) + \ln(\sigma) + 0.5(\frac{x-\mu}{\sigma})^2 $
df1b2variable nllNormal (const df1b2variable &x, const df1b2variable &mu, const double sigma)
df1b2variable nllNormal (const df1b2variable &x, const double mu, const df1b2variable &sigma)
df1b2variable nllNormal (const double x, const df1b2variable &mu, const df1b2variable &sigma)
df1b2variable nllNormal (const df1b2variable &x, const df1b2variable &mu, const df1b2variable &sigma)
double nllNormal (const dvector &x, const double mu, const double sigma)
 nll for normal for many samples, but mu is for common $ 0.5n\ln(2 \pi) + n\ln(\sigma) + 0.5\sum(\frac{x-\mu}{\sigma})^2 $
dvariable nllNormal (const dvar_vector &x, const double mu, const double sigma)
dvariable nllNormal (const dvector &x, const dvariable &mu, const dvariable &sigma)
dvariable nllNormal (const dvar_vector &x, const dvariable &mu, const dvariable &sigma)
df1b2variable nllNormal (const df1b2vector &x, const double mu, const double sigma)
 nll for normal for many samples, but mu is for common, overload for random effect $ 0.5n\ln(2 \pi) + n\ln(\sigma) + 0.5\sum(\frac{x-\mu}{\sigma})^2 $
df1b2variable nllNormal (const dvector &x, const df1b2variable &mu, const df1b2variable &sigma)
df1b2variable nllNormal (const df1b2vector &x, const df1b2variable &mu, const df1b2variable &sigma)
dvariable nllNormal (const dvar_vector &x, const dvector &mu, const double sigma)
 nll for normal for many samples, each has its own mean $ 0.5n\ln(2 \pi) + n\ln(\sigma) + 0.5\sum(\frac{x_{i}-\mu_{i}}{\sigma})^2 $
dvariable nllNormal (const dvector &x, const dvar_vector &mu, const dvariable &sigma)
dvariable nllNormal (const dvar_vector &x, const dvar_vector &mu, const dvariable &sigma)
df1b2variable nllNormal (const df1b2vector &x, const dvector &mu, const double sigma)
 nll for normal for many samples, each has its own mean for random effect $ 0.5n\ln(2 \pi) + n\ln(\sigma) + 0.5\sum(\frac{x_{i}-\mu_{i}}{\sigma})^2 $
df1b2variable nllNormal (const dvector &x, const df1b2vector &mu, const df1b2variable &sigma)
df1b2variable nllNormal (const df1b2vector &x, const df1b2vector &mu, const df1b2variable &sigma)
dvariable nllNormal2 (const dvariable &x, const double mu, const double tau)
 nll for normal(mu,tau) for one sample $ 0.5\ln(2 \pi) -0.5 \ln(\tau) + 0.5\tau(x-\mu)^2 $
dvariable nllNormal2 (const double x, const dvariable &mu, const dvariable &tau)
dvariable nllNormal2 (const dvariable &x, const dvariable &mu, const dvariable &tau)
df1b2variable nllNormal2 (const df1b2variable &x, const double mu, const double tau)
 nll for normal(mu,tau) for one sample for random effect $ 0.5\ln(2 \pi) -0.5 \ln(\tau) + 0.5\tau(x-\mu)^2 $
df1b2variable nllNormal2 (const double x, const df1b2variable &mu, const df1b2variable &tau)
df1b2variable nllNormal2 (const df1b2variable &x, const df1b2variable &mu, const df1b2variable &tau)
dvariable nllNormal2 (const dvar_vector &x, const double mu, const double tau)
 nll for normal(mu,tau) for many samples $ 0.5n\ln(2 \pi) -0.5n\ln(\tau) + 0.5\tau\sum(x-\mu)^2 $
dvariable nllNormal2 (const dvector &x, const dvariable &mu, const dvariable &tau)
dvariable nllNormal2 (const dvar_vector &x, const dvariable &mu, const dvariable &tau)
df1b2variable nllNormal2 (const df1b2vector &x, const double mu, const double tau)
 nll for normal(mu,tau) for many samples for random effect $ 0.5n\ln(2 \pi) -0.5n\ln(\tau) + 0.5\tau\sum(x-\mu)^2 $
df1b2variable nllNormal2 (const dvector &x, const df1b2variable &mu, const df1b2variable &tau)
df1b2variable nllNormal2 (const df1b2vector &x, const df1b2variable &mu, const df1b2variable &tau)
dvariable nllNormal2 (const dvar_vector &x, const dvector &mu, const double tau)
 nll for normal(mu,tau) for many samples, each has its own mean $ 0.5n\ln(2 \pi) + n\ln(\sigma) + 0.5\tau\sum(x_{i}-\mu_{i})^2 $
dvariable nllNormal2 (const dvector &x, const dvar_vector &mu, const dvariable &tau)
dvariable nllNormal2 (const dvar_vector &x, const dvar_vector &mu, const dvariable &tau)
df1b2variable nllNormal2 (const df1b2vector &x, const dvector &mu, const double tau)
 nll for normal(mu,tau) for many samples, each has its own mean, overload for random effect, $ 0.5n\ln(2 \pi) + n\ln(\sigma) + 0.5\tau\sum(x_{i}-\mu_{i})^2 $
df1b2variable nllNormal2 (const dvector &x, const df1b2vector &mu, const df1b2variable &tau)
df1b2variable nllNormal2 (const df1b2vector &x, const df1b2vector &mu, const df1b2variable &tau)
double nllPoisson (const double x, const double lambda)
 nll for poisson for one sample $ \lambda -x\ln(\lambda)+\ln(x!) $
dvariable nllPoisson (const dvariable &x, const double lambda)
dvariable nllPoisson (const double x, const dvariable &lambda)
dvariable nllPoisson (const dvariable &x, const dvariable &lambda)
df1b2variable nllPoisson (const df1b2variable &x, const double lambda)
 nll for poisson for one sample for random effect $ \lambda -x\ln(\lambda)+\ln(x!) $
df1b2variable nllPoisson (const double x, const df1b2variable &lambda)
df1b2variable nllPoisson (const df1b2variable &x, const df1b2variable &lambda)
dvariable nllPoisson (const dvar_vector &x, const double lambda)
 nll for poisson for many samples $ n\lambda -\sum(x)\ln(\lambda)+\sum(\ln(x!)) $
dvariable nllPoisson (const dvector &x, const dvariable &lambda)
dvariable nllPoisson (const dvar_vector &x, const dvariable &lambda)
df1b2variable nllPoisson (const dvector &x, const df1b2variable &lambda)
 nll for poisson for many samples for random effect $ n\lambda -\sum(x)\ln(\lambda)+\sum(\ln(x!)) $
df1b2variable nllPoisson (const df1b2vector &x, const double lambda)
df1b2variable nllPoisson (const df1b2vector &x, const df1b2variable &lambda)
dvar_vector normalize_p (dvar_vector &p, dvariable fpen)
 normailize p as sum(p)=1, return p and penalty if sum(p)!=1
df1b2vector normalize_p (df1b2vector &p, df1b2variable fpen)
int numRows4VarFromFile (adstring filename, adstring varName)
 get how many rows for one specific variable(varName) in admb output file(filename)
dvar_vector posfun (dvar_vector &x, const dvector &eps, dvariable &pen)
 overloading functions for posfun for vector and matrix, not sure if admb already do this in latest version
df1b2vector posfun (df1b2vector &x, const dvector &eps, df1b2variable &pen)
dvar_matrix posfun (dvar_matrix &x, const dmatrix &eps, dvariable &pen)
 overloading functions for posfun for vector and matrix, not sure if admb already do this in latest version
overloading function for matrix
df1b2matrix posfun (df1b2matrix &x, const dmatrix &eps, df1b2variable &pen)
double rbeta (double alpha, double beta, random_number_generator &rng)
 generate random beta(alpha, beta) number,
dvector rdirichlet (const dvector &shape, random_number_generator &rng)
 generate random dirichlet number
double rgamma (double alpha, random_number_generator &rng)
 generate random gamma number, pseudo code see http://en.wikipedia.org/wiki/Gamma_distribution , Gamma(alpha, belta)=x^(alpha-1)*belta^alpha*exp(-belta*x)/gamma(alpha)
double rgamma (double alpha, double beta, random_number_generator &rng)
 generate random gamma number, mean is alpha/belta, variance is alpha/(belta^2)
double rlnorm (double mu, double sigma, random_number_generator &rng)
 generate one random lognormal number LN(mu,sigma)
double rnorm (double mu, double sigma, random_number_generator &rng)
 generate one random normal number N(mu,sigma)
double runif (double low, double upper, random_number_generator &rng)
 generate one random uniform from (low,upper)
ivector sample (const dvector &source, int nSample, int withReplace, const random_number_generator &rng)
 generate a random sample index(size is nSample) based on the input samples(source) with or without replacement
dvector unique (const dvector &in)
 find the unique values from input vector and only return the unique (by remove the duplicate) values in ascending order
dmatrix vector2matrix (dvector &input, int nrow, int ncol, int byrow)
 convert the Vector as a Matrix eithter by row=1(default) or by column=0,
df1b2matrix vector2matrix (df1b2vector &input, int nrow, int ncol, int byrow)
 convert the Vector as a Matrix eithter by row=1(default) or by column=0, overloading function
dvar_matrix vector2matrix (const dvar_vector &input, int nrow, int ncol, int byrow)
 convert the Vector as a Matrix eithter by row=1(default) or by column=0, overloading function

Variables

const double EPS = 1.e-20
const double QFC_M_E = 1.e-20

Function Documentation

df1b2vector boundp ( const df1b2vector x,
const double  fmin,
const double  fmax,
const df1b2variable fpen 
)

Definition at line 250 of file qfc_est.cpp.

Definition at line 93 of file qfc_est.cpp.

df1b2vector log_comb ( const df1b2vector n,
const dvector x 
)

Definition at line 278 of file qfc_est.cpp.

df1b2vector log_comb ( const dvector n,
const df1b2vector x 
)

Definition at line 285 of file qfc_est.cpp.

Definition at line 62 of file qfc_est.cpp.

df1b2variable mf_upper_bound2 ( const df1b2variable x,
const double  fmax,
df1b2variable fpen 
)

Definition at line 220 of file qfc_est.cpp.

dvariable nllBeta ( const dvariable x,
const double  a,
const double  b 
)

Definition at line 891 of file qfc_est.cpp.

dvariable nllBeta ( const double  x,
const dvariable a,
const dvariable b 
)

Definition at line 899 of file qfc_est.cpp.

dvariable nllBeta ( const dvariable x,
const dvariable a,
const double  b 
)

Definition at line 907 of file qfc_est.cpp.

dvariable nllBeta ( const dvariable x,
const double  a,
const dvariable b 
)

Definition at line 915 of file qfc_est.cpp.

dvariable nllBeta ( const dvariable x,
const dvariable a,
const dvariable b 
)

Definition at line 923 of file qfc_est.cpp.

df1b2variable nllBeta ( const df1b2variable x,
const df1b2variable a,
const double  b 
)

Definition at line 946 of file qfc_est.cpp.

df1b2variable nllBeta ( const df1b2variable x,
const double  a,
const df1b2variable b 
)

Definition at line 952 of file qfc_est.cpp.

df1b2variable nllBeta ( const double  x,
const df1b2variable a,
const df1b2variable b 
)

Definition at line 958 of file qfc_est.cpp.

df1b2variable nllBeta ( const df1b2variable x,
const df1b2variable a,
const df1b2variable b 
)

Definition at line 964 of file qfc_est.cpp.

dvariable nllBeta ( const dvector x,
const dvariable a,
const dvariable b 
)

Definition at line 990 of file qfc_est.cpp.

dvariable nllBeta ( const dvar_vector x,
const dvariable a,
const dvariable b 
)

Definition at line 999 of file qfc_est.cpp.

df1b2variable nllBeta ( const dvector x,
const df1b2variable a,
const df1b2variable b 
)

Definition at line 1024 of file qfc_est.cpp.

df1b2variable nllBeta ( const df1b2vector x,
const df1b2variable a,
const df1b2variable b 
)

Definition at line 1031 of file qfc_est.cpp.

dvariable nllBinomial ( const dvariable x,
const double  n,
const double  p 
)

Definition at line 1519 of file qfc_est.cpp.

dvariable nllBinomial ( const double  x,
const dvariable n,
const dvariable p 
)

Definition at line 1527 of file qfc_est.cpp.

dvariable nllBinomial ( const dvariable x,
const dvariable n,
const dvariable p 
)

Definition at line 1535 of file qfc_est.cpp.

df1b2variable nllBinomial ( const double  x,
const df1b2variable n,
const df1b2variable p 
)

Definition at line 1558 of file qfc_est.cpp.

df1b2variable nllBinomial ( const df1b2variable x,
const df1b2variable n,
const df1b2variable p 
)

Definition at line 1564 of file qfc_est.cpp.

dvariable nllBinomial ( const dvector x,
const dvar_vector n,
const dvariable p 
)

Definition at line 1590 of file qfc_est.cpp.

dvariable nllBinomial ( const dvar_vector x,
const dvar_vector n,
const dvariable p 
)

Definition at line 1598 of file qfc_est.cpp.

df1b2variable nllBinomial ( const df1b2vector x,
const dvector n,
const double  p 
)

Definition at line 1621 of file qfc_est.cpp.

df1b2variable nllBinomial ( const df1b2vector x,
const df1b2vector n,
const df1b2variable p 
)

Definition at line 1627 of file qfc_est.cpp.

dvariable nllDirichlet ( const dvar_vector p,
const dvector shape 
)

Definition at line 639 of file qfc_est.cpp.

dvariable nllDirichlet ( const dvector p,
const dvar_vector shape 
)

Definition at line 647 of file qfc_est.cpp.

dvariable nllDirichlet ( const dvar_vector p,
const dvar_vector shape 
)

Definition at line 655 of file qfc_est.cpp.

df1b2variable nllDirichlet ( const dvector p,
const df1b2vector shape 
)

Definition at line 677 of file qfc_est.cpp.

df1b2variable nllDirichlet ( const df1b2vector p,
const df1b2vector shape 
)

Definition at line 683 of file qfc_est.cpp.

dvariable nllGamma ( const dvariable x,
const double  a,
const double  b 
)

Definition at line 712 of file qfc_est.cpp.

dvariable nllGamma ( const double  x,
const dvariable a,
const dvariable b 
)

Definition at line 720 of file qfc_est.cpp.

dvariable nllGamma ( const dvariable x,
const dvariable a,
const double  b 
)

Definition at line 728 of file qfc_est.cpp.

dvariable nllGamma ( const dvariable x,
const double  a,
const dvariable b 
)

Definition at line 736 of file qfc_est.cpp.

dvariable nllGamma ( const dvariable x,
const dvariable a,
const dvariable b 
)

Definition at line 744 of file qfc_est.cpp.

df1b2variable nllGamma ( const double  x,
const df1b2variable a,
const df1b2variable b 
)

Definition at line 768 of file qfc_est.cpp.

df1b2variable nllGamma ( const df1b2variable x,
const df1b2variable a,
const double  b 
)

Definition at line 774 of file qfc_est.cpp.

df1b2variable nllGamma ( const df1b2variable x,
const double  a,
const df1b2variable b 
)

Definition at line 780 of file qfc_est.cpp.

df1b2variable nllGamma ( const df1b2variable x,
const df1b2variable a,
const df1b2variable b 
)

Definition at line 786 of file qfc_est.cpp.

dvariable nllGamma ( const dvar_vector x,
const double  a,
const double  b 
)

Definition at line 810 of file qfc_est.cpp.

dvariable nllGamma ( const dvector x,
const dvariable a,
const dvariable b 
)

Definition at line 819 of file qfc_est.cpp.

dvariable nllGamma ( const dvar_vector x,
const dvariable a,
const dvariable b 
)

Definition at line 828 of file qfc_est.cpp.

df1b2variable nllGamma ( const dvector x,
const df1b2variable a,
const df1b2variable b 
)

Definition at line 853 of file qfc_est.cpp.

df1b2variable nllGamma ( const df1b2vector x,
const df1b2variable a,
const df1b2variable b 
)

Definition at line 860 of file qfc_est.cpp.

dvariable nllInverseGamma ( const dvariable x,
const double  a,
const double  b 
)

Definition at line 2280 of file qfc_est.cpp.

dvariable nllInverseGamma ( const double  x,
const dvariable a,
const dvariable b 
)

Definition at line 2288 of file qfc_est.cpp.

dvariable nllInverseGamma ( const dvariable x,
const dvariable a,
const dvariable b 
)

Definition at line 2296 of file qfc_est.cpp.

df1b2variable nllInverseGamma ( const double  x,
const df1b2variable a,
const df1b2variable b 
)

Definition at line 2319 of file qfc_est.cpp.

df1b2variable nllInverseGamma ( const df1b2variable x,
const df1b2variable a,
const double  b 
)

Definition at line 2325 of file qfc_est.cpp.

df1b2variable nllInverseGamma ( const df1b2variable x,
const double  a,
const df1b2variable b 
)

Definition at line 2331 of file qfc_est.cpp.

df1b2variable nllInverseGamma ( const df1b2variable x,
const df1b2variable a,
const df1b2variable b 
)

Definition at line 2337 of file qfc_est.cpp.

dvariable nllInverseGamma ( const dvector x,
const dvariable a,
const dvariable b 
)

Definition at line 2364 of file qfc_est.cpp.

dvariable nllInverseGamma ( const dvar_vector x,
const dvariable a,
const dvariable b 
)

Definition at line 2373 of file qfc_est.cpp.

df1b2variable nllInverseGamma ( const df1b2vector x,
const double  a,
const double  b 
)

Definition at line 2398 of file qfc_est.cpp.

df1b2variable nllInverseGamma ( const df1b2vector x,
const df1b2variable a,
const df1b2variable b 
)

Definition at line 2405 of file qfc_est.cpp.

dvariable nllLognormal ( const dvariable x,
const double  mu,
const double  sigma 
)

Definition at line 1661 of file qfc_est.cpp.

dvariable nllLognormal ( const double  x,
const dvariable mu,
const dvariable sigma 
)

Definition at line 1669 of file qfc_est.cpp.

dvariable nllLognormal ( const dvariable x,
const dvariable mu,
const double  sigma 
)

Definition at line 1677 of file qfc_est.cpp.

dvariable nllLognormal ( const dvariable x,
const double  mu,
const dvariable sigma 
)

Definition at line 1685 of file qfc_est.cpp.

dvariable nllLognormal ( const dvariable x,
const dvariable mu,
const dvariable sigma 
)

Definition at line 1693 of file qfc_est.cpp.

df1b2variable nllLognormal ( const double  x,
const df1b2variable mu,
const df1b2variable sigma 
)

Definition at line 1716 of file qfc_est.cpp.

df1b2variable nllLognormal ( const df1b2variable x,
const df1b2variable mu,
const double  sigma 
)

Definition at line 1722 of file qfc_est.cpp.

df1b2variable nllLognormal ( const df1b2variable x,
const double  mu,
const df1b2variable sigma 
)

Definition at line 1728 of file qfc_est.cpp.

df1b2variable nllLognormal ( const df1b2variable x,
const df1b2variable mu,
const df1b2variable sigma 
)

Definition at line 1734 of file qfc_est.cpp.

dvariable nllLognormal ( const dvector x,
const dvariable mu,
const dvariable sigma 
)

Definition at line 1761 of file qfc_est.cpp.

dvariable nllLognormal ( const dvar_vector x,
const dvariable mu,
const dvariable sigma 
)

Definition at line 1770 of file qfc_est.cpp.

df1b2variable nllLognormal ( const dvector x,
const df1b2variable mu,
const df1b2variable sigma 
)

Definition at line 1795 of file qfc_est.cpp.

df1b2variable nllLognormal ( const df1b2vector x,
const df1b2variable mu,
const df1b2variable sigma 
)

Definition at line 1802 of file qfc_est.cpp.

dvariable nllLognormal ( const dvector x,
const dvar_vector mu,
const dvariable sigma 
)

Definition at line 1829 of file qfc_est.cpp.

dvariable nllLognormal ( const dvar_vector x,
const dvar_vector mu,
const dvariable sigma 
)

Definition at line 1838 of file qfc_est.cpp.

df1b2variable nllLognormal ( const dvector x,
const df1b2vector mu,
const df1b2variable sigma 
)

Definition at line 1863 of file qfc_est.cpp.

df1b2variable nllLognormal ( const df1b2vector x,
const df1b2vector mu,
const df1b2variable sigma 
)

Definition at line 1870 of file qfc_est.cpp.

dvariable nllLognormal2 ( const dvariable x,
const double  mu,
const double  tau 
)

Definition at line 1905 of file qfc_est.cpp.

dvariable nllLognormal2 ( const dvariable x,
const dvariable mu,
const dvariable tau 
)

Definition at line 1913 of file qfc_est.cpp.

df1b2variable nllLognormal2 ( const double  x,
const df1b2variable mu,
const df1b2variable tau 
)

Definition at line 1936 of file qfc_est.cpp.

df1b2variable nllLognormal2 ( const df1b2variable  x,
const df1b2variable mu,
const double  tau 
)

Definition at line 1942 of file qfc_est.cpp.

df1b2variable nllLognormal2 ( const df1b2variable  x,
const double  mu,
const df1b2variable tau 
)

Definition at line 1948 of file qfc_est.cpp.

df1b2variable nllLognormal2 ( const df1b2variable  x,
const df1b2variable mu,
const df1b2variable tau 
)

Definition at line 1954 of file qfc_est.cpp.

dvariable nllLognormal2 ( const dvector x,
const dvariable mu,
const dvariable tau 
)

Definition at line 1981 of file qfc_est.cpp.

dvariable nllLognormal2 ( const dvar_vector x,
const dvariable mu,
const dvariable tau 
)

Definition at line 1990 of file qfc_est.cpp.

df1b2variable nllLognormal2 ( const df1b2vector x,
const double  mu,
const double  tau 
)

Definition at line 2015 of file qfc_est.cpp.

df1b2variable nllLognormal2 ( const df1b2vector x,
const df1b2variable mu,
const double  tau 
)

Definition at line 2022 of file qfc_est.cpp.

df1b2variable nllLognormal2 ( const df1b2vector x,
const double  mu,
const df1b2variable tau 
)

Definition at line 2029 of file qfc_est.cpp.

df1b2variable nllLognormal2 ( const df1b2vector x,
const df1b2variable mu,
const df1b2variable tau 
)

Definition at line 2036 of file qfc_est.cpp.

dvariable nllLognormal2 ( const dvector x,
const dvar_vector mu,
const dvariable tau 
)

Definition at line 2064 of file qfc_est.cpp.

dvariable nllLognormal2 ( const dvar_vector x,
const dvar_vector mu,
const dvariable tau 
)

Definition at line 2073 of file qfc_est.cpp.

df1b2variable nllLognormal2 ( const dvector x,
const df1b2vector mu,
const df1b2variable tau 
)

Definition at line 2098 of file qfc_est.cpp.

df1b2variable nllLognormal2 ( const df1b2vector x,
const df1b2vector mu,
const df1b2variable tau 
)

Definition at line 2105 of file qfc_est.cpp.

dvariable nllMultiNomial ( const dvector obsN,
const dvar_vector p 
)

Definition at line 566 of file qfc_est.cpp.

dvariable nllMultiNomial ( const dvar_vector obsN,
const dvector p 
)

Definition at line 574 of file qfc_est.cpp.

dvariable nllMultiNomial ( const dvar_vector obsN,
const dvar_vector p 
)

Definition at line 582 of file qfc_est.cpp.

df1b2variable nllMultiNomial ( const dvector obsN,
const df1b2vector p 
)

Definition at line 604 of file qfc_est.cpp.

df1b2variable nllMultiNomial ( const df1b2vector obsN,
const df1b2vector p 
)

Definition at line 610 of file qfc_est.cpp.

dvariable nllNegativeBinomial ( const dvariable obs,
const double  m,
const double  s 
)

Definition at line 321 of file qfc_est.cpp.

dvariable nllNegativeBinomial ( const double  obs,
const dvariable m,
const dvariable s 
)

Definition at line 329 of file qfc_est.cpp.

dvariable nllNegativeBinomial ( const dvariable obs,
const dvariable m,
const double  s 
)

Definition at line 337 of file qfc_est.cpp.

dvariable nllNegativeBinomial ( const dvariable obs,
const double  m,
const dvariable s 
)

Definition at line 345 of file qfc_est.cpp.

dvariable nllNegativeBinomial ( const dvariable obs,
const dvariable m,
const dvariable s 
)

Definition at line 353 of file qfc_est.cpp.

df1b2variable nllNegativeBinomial ( const double  obs,
const df1b2variable m,
const df1b2variable s 
)

Definition at line 378 of file qfc_est.cpp.

df1b2variable nllNegativeBinomial ( const df1b2variable obs,
const df1b2variable m,
const double  s 
)

Definition at line 384 of file qfc_est.cpp.

df1b2variable nllNegativeBinomial ( const df1b2variable obs,
const double  m,
const df1b2variable s 
)

Definition at line 390 of file qfc_est.cpp.

df1b2variable nllNegativeBinomial ( const df1b2variable obs,
const df1b2variable m,
const df1b2variable s 
)

Definition at line 396 of file qfc_est.cpp.

dvariable nllNegativeBinomial ( const dvar_vector obs,
const double  m,
const double  s 
)

Definition at line 426 of file qfc_est.cpp.

dvariable nllNegativeBinomial ( const dvar_vector obs,
const dvariable m,
const dvariable s 
)

Definition at line 435 of file qfc_est.cpp.

df1b2variable nllNegativeBinomial ( const dvector obs,
const df1b2variable m,
const df1b2variable s 
)

Definition at line 462 of file qfc_est.cpp.

df1b2variable nllNegativeBinomial ( const df1b2vector obs,
const df1b2variable m,
const df1b2variable s 
)

Definition at line 469 of file qfc_est.cpp.

dvariable nllNegativeBinomial2 ( const double  obs,
const dvariable m,
const dvariable tau 
)

Definition at line 499 of file qfc_est.cpp.

dvariable nllNegativeBinomial2 ( const dvariable obs,
const double  m,
const double  tau 
)

Definition at line 503 of file qfc_est.cpp.

dvariable nllNegativeBinomial2 ( const dvariable obs,
const dvariable m,
const double  tau 
)

Definition at line 507 of file qfc_est.cpp.

dvariable nllNegativeBinomial2 ( const dvariable obs,
const double  m,
const dvariable tau 
)

Definition at line 511 of file qfc_est.cpp.

dvariable nllNegativeBinomial2 ( const dvariable obs,
const dvariable m,
const dvariable tau 
)

Definition at line 515 of file qfc_est.cpp.

df1b2variable nllNegativeBinomial2 ( const double  obs,
const df1b2variable m,
const df1b2variable tau 
)

Definition at line 533 of file qfc_est.cpp.

df1b2variable nllNegativeBinomial2 ( const df1b2variable obs,
const df1b2variable m,
const df1b2variable tau 
)

Definition at line 537 of file qfc_est.cpp.

dvariable nllNormal ( const dvariable x,
const double  mu,
const double  sigma 
)

Definition at line 1062 of file qfc_est.cpp.

dvariable nllNormal ( const double  x,
const dvariable mu,
const dvariable sigma 
)

Definition at line 1070 of file qfc_est.cpp.

dvariable nllNormal ( const dvariable x,
const dvariable mu,
const double  sigma 
)

Definition at line 1078 of file qfc_est.cpp.

dvariable nllNormal ( const dvariable x,
const double  mu,
const dvariable sigma 
)

Definition at line 1086 of file qfc_est.cpp.

dvariable nllNormal ( const dvariable x,
const dvariable mu,
const dvariable sigma 
)

Definition at line 1094 of file qfc_est.cpp.

df1b2variable nllNormal ( const df1b2variable x,
const df1b2variable mu,
const double  sigma 
)

Definition at line 1117 of file qfc_est.cpp.

df1b2variable nllNormal ( const df1b2variable x,
const double  mu,
const df1b2variable sigma 
)

Definition at line 1123 of file qfc_est.cpp.

df1b2variable nllNormal ( const double  x,
const df1b2variable mu,
const df1b2variable sigma 
)

Definition at line 1129 of file qfc_est.cpp.

df1b2variable nllNormal ( const df1b2variable x,
const df1b2variable mu,
const df1b2variable sigma 
)

Definition at line 1135 of file qfc_est.cpp.

dvariable nllNormal ( const dvar_vector x,
const double  mu,
const double  sigma 
)

Definition at line 1159 of file qfc_est.cpp.

dvariable nllNormal ( const dvector x,
const dvariable mu,
const dvariable sigma 
)

Definition at line 1168 of file qfc_est.cpp.

dvariable nllNormal ( const dvar_vector x,
const dvariable mu,
const dvariable sigma 
)

Definition at line 1177 of file qfc_est.cpp.

df1b2variable nllNormal ( const dvector x,
const df1b2variable mu,
const df1b2variable sigma 
)

Definition at line 1202 of file qfc_est.cpp.

df1b2variable nllNormal ( const df1b2vector x,
const df1b2variable mu,
const df1b2variable sigma 
)

Definition at line 1209 of file qfc_est.cpp.

dvariable nllNormal ( const dvector x,
const dvar_vector mu,
const dvariable sigma 
)

Definition at line 1236 of file qfc_est.cpp.

dvariable nllNormal ( const dvar_vector x,
const dvar_vector mu,
const dvariable sigma 
)

Definition at line 1245 of file qfc_est.cpp.

df1b2variable nllNormal ( const dvector x,
const df1b2vector mu,
const df1b2variable sigma 
)

Definition at line 1270 of file qfc_est.cpp.

df1b2variable nllNormal ( const df1b2vector x,
const df1b2vector mu,
const df1b2variable sigma 
)

Definition at line 1277 of file qfc_est.cpp.

dvariable nllNormal2 ( const double  x,
const dvariable mu,
const dvariable tau 
)

Definition at line 1312 of file qfc_est.cpp.

dvariable nllNormal2 ( const dvariable x,
const dvariable mu,
const dvariable tau 
)

Definition at line 1320 of file qfc_est.cpp.

df1b2variable nllNormal2 ( const double  x,
const df1b2variable mu,
const df1b2variable tau 
)

Definition at line 1343 of file qfc_est.cpp.

df1b2variable nllNormal2 ( const df1b2variable x,
const df1b2variable mu,
const df1b2variable tau 
)

Definition at line 1349 of file qfc_est.cpp.

dvariable nllNormal2 ( const dvector x,
const dvariable mu,
const dvariable tau 
)

Definition at line 1376 of file qfc_est.cpp.

dvariable nllNormal2 ( const dvar_vector x,
const dvariable mu,
const dvariable tau 
)

Definition at line 1385 of file qfc_est.cpp.

df1b2variable nllNormal2 ( const dvector x,
const df1b2variable mu,
const df1b2variable tau 
)

Definition at line 1410 of file qfc_est.cpp.

df1b2variable nllNormal2 ( const df1b2vector x,
const df1b2variable mu,
const df1b2variable tau 
)

Definition at line 1417 of file qfc_est.cpp.

dvariable nllNormal2 ( const dvector x,
const dvar_vector mu,
const dvariable tau 
)

Definition at line 1444 of file qfc_est.cpp.

dvariable nllNormal2 ( const dvar_vector x,
const dvar_vector mu,
const dvariable tau 
)

Definition at line 1453 of file qfc_est.cpp.

df1b2variable nllNormal2 ( const dvector x,
const df1b2vector mu,
const df1b2variable tau 
)

Definition at line 1478 of file qfc_est.cpp.

df1b2variable nllNormal2 ( const df1b2vector x,
const df1b2vector mu,
const df1b2variable tau 
)

Definition at line 1485 of file qfc_est.cpp.

dvariable nllPoisson ( const dvariable x,
const double  lambda 
)

Definition at line 2138 of file qfc_est.cpp.

dvariable nllPoisson ( const double  x,
const dvariable lambda 
)

Definition at line 2146 of file qfc_est.cpp.

dvariable nllPoisson ( const dvariable x,
const dvariable lambda 
)

Definition at line 2154 of file qfc_est.cpp.

df1b2variable nllPoisson ( const double  x,
const df1b2variable lambda 
)

Definition at line 2176 of file qfc_est.cpp.

df1b2variable nllPoisson ( const df1b2variable x,
const df1b2variable lambda 
)

Definition at line 2182 of file qfc_est.cpp.

dvariable nllPoisson ( const dvector x,
const dvariable lambda 
)

Definition at line 2207 of file qfc_est.cpp.

dvariable nllPoisson ( const dvar_vector x,
const dvariable lambda 
)

Definition at line 2216 of file qfc_est.cpp.

df1b2variable nllPoisson ( const df1b2vector x,
const double  lambda 
)

Definition at line 2240 of file qfc_est.cpp.

df1b2variable nllPoisson ( const df1b2vector x,
const df1b2variable lambda 
)

Definition at line 2247 of file qfc_est.cpp.

Definition at line 122 of file qfc_est.cpp.

df1b2vector posfun ( df1b2vector x,
const dvector eps,
df1b2variable pen 
)

Definition at line 150 of file qfc_est.cpp.

df1b2matrix posfun ( df1b2matrix x,
const dmatrix eps,
df1b2variable pen 
)

Definition at line 183 of file qfc_est.cpp.


Variable Documentation

const double EPS = 1.e-20
const double QFC_M_E = 1.e-20

Definition at line 43 of file qfclib.h.

Referenced by rgamma().