Learn R Programming

SimComp (version 1.4.5)

SimTestRat: Simultaneous Tests for Ratios of Means of Multiple Endpoints

Description

Simultaneous tests for ratios of contrasts (linear functions) of normal means (e.g., "Dunnett", "Tukey", "Williams" ect.) when there is more than one primary response variable (endpoint). The procedure of Hasler and Hothorn (2011) is applied for ratios of means of normally distributed data. The covariance matrices (containing the covariances between the endpoints) may be assumed to be equal or possibly unequal for the different groups. For the case of only a single endpoint, the procedure coincides with the PI procedure of Hasler and Hothorn (2008).

Usage

SimTestRat(data, grp, resp = NULL, type = "Dunnett", base = 1, Num.Contrast = NULL,
           Den.Contrast = NULL, alternative = "two.sided", Margin = NULL,
           covar.equal = FALSE)

Arguments

data
a data frame containing a grouping variable and the endpoints as columns
grp
a character string with the name of the grouping variable
resp
a vector of character strings with the names of the endpoints; if resp=NULL (default), all column names of the data frame without the grouping variable are chosen automatically
type
a character string, defining the type of contrast, with the following options:
  • "Dunnett": many-to-one comparisons, with control in the denominator
  • "Tukey": all-pair compari
base
a single integer specifying the control (i.e. denominator) group for Dunnett contrasts, ignored otherwise
Num.Contrast
a numerator contrast matrix, where columns correspond to groups and rows correspond to contrasts
Den.Contrast
a denominator contrast matrix, where columns correspond to groups and rows correspond to contrasts
alternative
a character string specifying the alternative hypothesis, must be one of "two.sided" (default), "greater" or "less"
Margin
a single numeric value, or a numeric vector corresponding to endpoints, or a matrix where columns correspond to endpoints and rows correspond to contrasts, default is 1
covar.equal
a logical variable indicating whether to treat the covariance matrices (containing the covariances between the endpoints) for the different groups as being equal; if TRUE th

Value

  • An object of class SimTest containing:
  • estimatea matrix of estimated ratios
  • statistica matrix of the calculated test statistics
  • p.val.rawa matrix of raw p-values
  • p.val.adja matrix of p-values adjusted for multiplicity
  • CorrMatDateither the estimated common correlation matrix of the data (covar.equal=TRUE) or the list of the different (one for each treatment) estimated correlation matrices of the data (covar.equal=FALSE)
  • CorrMatCompthe estimated correlation matrix to be used for the multivariate t-distribution
  • degr.freither a single degree of freedom (covar.equal=TRUE) or a matrix of degrees of freedom (covar.equal=FALSE)

Details

The interest is in simultaneous tests for several ratios of linear combinations (contrasts) of treatment means in a one-way ANOVA model, and simultaneously for multiple endpoints. For example, the all-pair comparison of Tukey (1953) and the many-to-one comparison of Dunnett (1955) for ratios of means are implemented, but allowing for multiple endpoints. Also, the user is free to create other interesting problem-specific contrasts. An approximate multivariate t-distribution is used to calculate (adjusted) p-values (see Hasler and Hothorn, 2011). This approach controls the familywise error rate in an admissible range and in the strong sense. The covariance matrices of the treatment groups (containing the covariances between the endpoints) can be assumed to be equal (covar.equal=TRUE) or unequal (covar.equal=FALSE). If being equal, the pooled covariance matrix is used, otherwise the Satterthwaite approximation to the degrees of freedom is used according to Hasler and Hothorn (2008). Unequal covariance matrices occure if variances or correlations of some endpoints differ depending on the treatment groups.

References

Hasler, M. and Hothorn, L.A. (2011): A Dunnett-type procedure for multiple endpoints. The International Journal of Biostatistics. Hasler, M. and Hothorn, L.A. (2008): Multiple contrast tests in the presence of heteroscedasticity. Biometrical Journal 50, 793-800. Dilba, G. et al. (2006): Simultaneous confidence sets and confidence intervals for multiple ratios. Journal of Statistical Planning and Inference 136, 2640-2658.

See Also

SimTestDiff, SimCiRat, SimCiDiff,

Examples

Run this code
# Example 1:
# A Dunnett-test for the groups B and H against the standard S, on the (single)
# endpoint Thromb.count, assuming unequal variances for the groups, and in terms of
# ratios. This is the well-known Dunnett-test but in the presence of
# heteroscedasticity and for ratios of means.

data(coagulation)

comp1 <- SimTestRat(data=coagulation, grp="Group", resp="Thromb.count", type="Dunnett",
  base=3, alternative="greater", covar.equal=FALSE)
comp1

# Example 2:
# A Dunnett-test for the groups B and H against the standard S, simultaneously on
# all endpoints, assuming unequal covariance matrices for the groups, and in terms
# of ratios.

data(coagulation)

comp2 <- SimTestRat(data=coagulation, grp="Group", resp=c("Thromb.count","ADP","TRAP"), type="Dunnett",
  base=3, alternative="greater", covar.equal=FALSE)
summary(comp2)

Run the code above in your browser using DataLab