cdtamodel {CopulaDTA}R Documentation

Specify the copula based bivariate beta-binomial distribution to fit to the diagnostic data.

Description

Specify the copula based bivariate beta-binomial distribution to fit to the diagnostic data.

Usage

cdtamodel(copula, modelargs = list())

Arguments

copula

a description of the copula function used to model the correlation between sensitivity and specificty. This is a string naming the copula function. The choices are "fgm", "frank", "gauss", "c90" and "c270".

modelargs

a (optional) list of control parameter for the prior distributions. The parameters in the list include:

  • formula.se An object of class "formula": A symbolic description of a linear model to be fitted to mean E(x) of sensitivity in the logit scale. the default (when no covariates are included) symbolic description is SID ~ 1 corresponds to the model formula E(x) = mu = exp(a)/(1 + exp(a)) where a is the intercept. When the covariates are categorical and the relative measures are needed it is important to remove the interecept from the model to obtain meaningful parameters. EG for a covariate 'Test' with two levels(A and B) and relative sensitivity of B versus A is needed, then the correct formula is SID ~ Test - 1 or SID ~ Test + 0. See formula. For further information on interpretation of parameters in logistic regression see Agresti A(2002) Chapter 5.

  • formula.sp An object of class "formula": A symbolic description of a linear model to be fitted to specificity data. By default the covariate information for sensitivity is used.

  • formula.omega An object of class "formula": A symbolic description of a linear model to be fitted to the copula function. By default the covariate information for sensitivity is used.

  • transform.omega A logical value indicating whether a constrained correlation parameter should be mapped into an non-constrained scale. This applies to all the allowed copula functions except "frank". The default is TRUE.

  • param indication of the parameterisation used to map the marginal mean and precision/dispersion to the alpha and beta parameters of the beta distribution. There are two choices: param=1 which uses

    alpha = mu*phi, beta = (1 - mu)*phi

    where

    mu = alpha/(alpha + beta), 0<=mu<=1,

    and

    phi = alpha + beta, phi >= 0.

    param=2 uses

    alpha = ((1 - phi)/phi)*mu

    beta = ((1 - phi)/phi)*(1 - mu)

    where

    mu = alpha/(alpha + beta); 0<=mu<=1,

    and

    phi = 1/( 1 + alpha + beta); 0<=phi<=1.

  • prior.lseA description of prior distribution of the marginal mean sensitivity in the logit scale. The default is "normal" distribution. For other distributions see stan documentation at http://mc-stan.org/documentation/.

  • par.lse1A numeric value indicating the location of the prior distribution of the marginal mean sensitivity in the logit scale. The default is 0 which implying a distribution centered around 0.5 in the 0-1 scale.

  • par.lse2A numeric value indicating the spread(standard deviation) pf the prior distribution of the marginal mean sensitivity in the logit scale and can be interpreted as the quantity of prior information. vague and non-informative priors are specified by a distribution with large variance. The default is sd=10 implying that the variance is 100.

  • prior.lspA description of prior distribution of the marginal mean specificity in the logit scale. The default is "normal" distribution.

  • par.lsp1A numeric value indicating the location of the prior distribution of the marginal mean specificity in the logit scale. The default is 0 which implying a distribution centered around 0.5 in the 0-1 scale.

  • par.lsp2A numeric value indicating the spread(standard deviation) pf the prior distribution of the marginal mean specificity in the logit scale and can be interpreted as the quantity of prior information. vague and non-informative priors are specified by a distribution with large variance. The default is sd=10 implying that the variance is 100.

  • prior.omegaA description of prior distribution of the correlation parameter(s). The default is "normal" distribution since "transform.omega=TRUE". When "transform.omega=FALSE" the candidate prior distributions are U[-1, 1] for fgm and gaussian copulas, and half-cauchy(0, 2.5), gamma(0.001, 0.001) for the C90 and C270.

  • par.omega1A numeric value indicating the location of the prior distribution of the correlation parameter(s). The default is 0.

  • par.omega2A numeric value indicating the scale/spread(standard deviation) of the prior distribution of the correlation parameter(s). The default is sd=10.

Value

An object of cdtamodel class.

Author(s)

Victoria N Nyaga

References

Nyaga VN, Arbyn M, Aerts M (2017). CopulaDTA: An R Package for Copula-Based Beta-Binomial Models for Diagnostic Test Accuracy Studies in a Bayesian Framework. Journal of Statistical Software, 82(1), 1-27. doi:10.18637/jss.v082.c01

Agresti A (2002). Categorical Data Analysis. John Wiley & Sons, Inc.

Clayton DG (1978). A model for Association in Bivariate Life Tables and its Application in Epidemiological Studies of Familial Tendency in Chronic Disease Incidence. Biometrika,65(1), 141-151.

Frank MJ (1979). On The Simultaneous Associativity of F(x, y) and x + y - F(x, y). Aequationes Mathematicae, pp. 194-226.

Farlie DGJ (1960). The Performance of Some Correlation Coefficients for a General Bivariate Distribution. Biometrika, 47, 307-323.

Gumbel EJ (1960). Bivariate Exponential Distributions. Journal of the American Statistical Association, 55, 698-707.

Meyer C (2013). The Bivariate Normal Copula. Communications in Statistics - Theory and Methods, 42(13), 2402-2422.

Morgenstern D (1956). Einfache Beispiele Zweidimensionaler Verteilungen. Mitteilungsblatt furMathematische Statistik, 8, 23 - 235.

Sklar A (1959). Fonctions de Repartition a n Dimensions et Leurs Marges. Publications de l'Institut de Statistique de L'Universite de Paris, 8, 229-231.

Examples

data(telomerase)
model1 <-  cdtamodel(copula = 'fgm')

model2 <- cdtamodel(copula = 'fgm',
               modelargs=list(param=2,
                              prior.lse='normal',
                              par.lse1=0,
                              par.lse2=5,
                              prior.lsp='normal',
                              par.lsp1=0,
                              par.lsp2=5))

model3 <-  cdtamodel(copula = 'fgm',
               modelargs = list(formula.se = StudyID ~ Test - 1))

[Package CopulaDTA version 1.0.0 Index]