computePosterior) and subsequent call to getPosteriorParam will fill all additional slots.newCounts.counts:"integer". An integer vector of positive numbers (counts). Mandatory for object initialization.fractions:"numeric". A numeric vector of the corresponding sampling fractions (real numbers in (0,1]). Mandatory for object initialization.n1:"numeric". Left endpoint of the prior support interval. If not provided and total counts are not zero, computed using the maximum likelihood estimate (mle) of the population size as 0.5 * mle.n2:"numeric". Right endpoint of the prior support interval. If not provided and total counts are not zero, computed using the maximum likelihood estimate (mle) of the population size as 2 * mle.X:"numeric". The product of (1 - fractions).mle:"numeric". The maximum likelihood estimate of the population size, computed as K/R, where K is the total counts and R is the total sampling fraction.nconst:"numeric". The normalization constant (see Corollary 1 in the reference for details).posterior:"ANY". A vector of posterior probabities over the prior support. It containes either the PMF or a logical value used to obtain posterior parameters with a Gamma approximation (see reference for details).map.p:"numeric". The maximum posterior probability.map.idx:"numeric". The index of the prior support corresponding to the maximum a posteriori (MAP), i.e. MAP - n1 + 1.map:"numeric". The MAP of the population size.qlow.p:"numeric". The probability of the left endpoint (q1) of the credible interval. Default confidence level 95%.qlow.idx:"integer". The index of the prior support corresponding to q1.qlow:"numeric". The left endpoint (q1) of the credible interval.qlow.cum:"numeric". The cumulative posterior probability from n1 to q1, i.e. the left tail.qup.p:"numeric". The probability of the right endpoint (q2) of the credible interval. Default confidence level 95%.qup.idx:"integer". The index of the prior support corresponding to q2.qup:"numeric". The right endpoint (q2) of the credible interval.qup.cum:"numeric". The cumulative posterior probability from q2 to n2, i.e. the right tail.gamma:"logical". TRUE if the posterior was computed using a Gamma approximation (see reference for details).newCounts
# create an object of class 'Counts' by using new
new('Counts', counts = c(30, 35), fractions = c(0.075, 0.1))
#or by means of the constructor
newCounts(counts = c(30, 35), fractions = c(0.075, 0.1))
Run the code above in your browser using DataLab