simint               package:multcomp               R Documentation

_S_i_m_u_l_t_a_n_e_o_u_s _C_o_n_f_i_d_e_n_c_e _I_n_t_e_r_v_a_l_s

_D_e_s_c_r_i_p_t_i_o_n:

     Computes simultaneous intervals for several multiple procedures.

_U_s_a_g_e:

     ## Default S3 method:
     simint(y, x=NULL, type=c("Dunnett", "Tukey",
            "Sequen", "AVE", "Changepoint", "Williams", "Marcus",
            "McDermott","Tetrade"), cmatrix=NULL, conf.level=0.95,
            alternative=c("two.sided","less", "greater"), 
            asympt=FALSE, eps=0.001, maxpts=1e+06, nlevel=NULL, 
            nzerocol=c(0,0),...)
     ## S3 method for class 'formula':
     simint(formula, data=list(), subset, na.action, whichf, ...)
     ## S3 method for class 'lm':
     simint(y, psubset=NULL, conf.level=0.95, cmatrix = NULL, 
            alternative=c("two.sided","less", "greater"), 
            asympt=FALSE, eps=0.001, maxpts=1e+06, ...)

_A_r_g_u_m_e_n_t_s:

       y: a numeric vector of responses or an object of class 'lm' or
          'glm'.

       x: a numeric matrix, the design matrix.

    type: the type of contrast to be used.

 cmatrix: the contrast matrix itself can be specified. If 'cmatrix' is
          defined, 'type' is ignored.

conf.level: confidence level.

alternative: the alternative hypothesis must be one of '"two.sided"'
          (default), '"greater"' or '"less"'.  You can specify just the
          initial letter.

  asympt: a logical indicating whether the (exact) t-distribution or
          the normal approximation should be used.

     eps: absolute error tolerance as double.

  maxpts: maximum number of function values as integer.

  nlevel: a vector containing the number of levels for each factor for
          'type == "Tetrade"'.

nzerocol: a vector of two elements defining the number of zero-columns
          to add to the contrast matrix from left (the first element,
          usually 1 for the intercept) and right (usually 0 if no
          covariables are specified). 'nzerocol' is automatically
          determined by 'simint.formula'.

 psubset: a vector of integers or characters indicating for which
          subset of coefficients of a (generalized) linear model 'y' 
          simultaneous confidences intervals should be computed.

 formula: a symbolic description of the model to be fit.

    data: an optional data frame containing the variables in the model.
          By default the variables are taken from
          'Environment(formula)', typically the environment from which
          'simint' is called.

  subset: an optional vector specifying a subset of observations to be
          used.

na.action: a function which indicates what should happen when the data
          contain 'NA''s.  Defaults to 'GetOption("na.action")'.

  whichf: if more than one factor is given in the right hand side of
          'formula', 'whichf' can be used to defined the factor to
          compute contrasts of.

     ...: further arguments to be passed to or from methods.

_D_e_t_a_i_l_s:

     Computes simultaneous confidence intervals for several multiple
     comparisons.  The  implemented algorithms take the stochastical
     correlations between the test statistics into account. Only single
     step comparisons are performed. The present function allows for
     multiple comparisons of generally correlated means in general
     linear models under the classical ANOVA assumptions, as well as
     more general approximate procedures for  approximately normal and
     generally correlated parameter estimates. Either multivariate 
     normal or multivariate t statistics can be used. The interface
     allows the use of the multiple comparison procedures as for
     example Dunnett and Tukey.  The resulting confidence intervals are
     not associated with the p-values from 'simtest'.

     See 'simtest' for detailed information on the formula interface.

_V_a_l_u_e:

     an object of class 'hmtest'

_A_u_t_h_o_r(_s):

     Frank Bretz <bretz@ifgb.uni-hannover.de> and  
       Torsten Hothorn <Torsten.Hothorn@rzmail.uni-erlangen.de>

_R_e_f_e_r_e_n_c_e_s:

     Frank Bretz, Alan Genz and Ludwig A. Hothorn (2001), On the
     numerical  availability of multiple comparison procedures.
     _Biometrical Journal_, *43*(5), 645-656.

_S_e_e _A_l_s_o:

     'TukeyHSD' for the special case of Tukey contrasts.

_E_x_a_m_p_l_e_s:

     data(recovery)

     # one-sided simultaneous confidence intervals for Dunnett 
     # in the one-way layout
     summary(simint(minutes~blanket, data=recovery, type="Dunnett", 
                    conf.level=0.9, alternative="less",eps=0.0001))

     # alternatively via a prespecified linear model
     lmmod <- lm(minutes ~ blanket, data=recovery, contrasts=list(blanket =
                 "contr.Dunnett"))
     summary(simint(lmmod, psubset=2:4, conf.level=0.9,
                    alternative="less",eps=0.0001))

     # Tukey confidence intervals, compare with TukeyHSD

     data(warpbreaks)
     fm1 <- aov(breaks ~ wool + tension, data = warpbreaks)
     tHSD <- TukeyHSD(fm1, "tension", ordered = FALSE)
     print(tHSD)

     mcHSD <- simint(breaks ~ wool + tension, data = warpbreaks, 
                     whichf="tension", type="Tukey")
     print(mcHSD)
     plot(mcHSD)

