SSD                  package:stats                  R Documentation

_S_S_D _M_a_t_r_i_x _a_n_d _E_s_t_i_m_a_t_e_d _V_a_r_i_a_n_c_e _M_a_t_r_i_x _i_n _M_u_l_t_i_v_a_r_i_a_t_e _M_o_d_e_l_s

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

     Functions to compute matrix of residual sums of squares and
     products, or the estimated variance matrix for multivariate linear
     models.

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

     # S3 method for class 'mlm'
     SSD(object, ...)

     # S3 methods for class 'SSD' and 'mlm'
     estVar(object, ...)

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

  object: 'object' of class '"mlm"', or '"SSD"' in the case of
          'estVar'.

     ...: Unused

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

     'SSD()' returns a list of class '"SSD"' containing the following
     components 

     SSD: The residual sums of squares and products matrix

      df: Degrees of freedom

    call: Copied from 'object'


     'estVar' returns a matrix with the estimated variances and
     covariances.

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

     'mauchly.test', 'anova.mlm'

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

     # Lifted from Baron+Li:
     # "Notes on the use of R for psychology experiments and questionnaires"
     # Maxwell and Delaney, p. 497
     reacttime <- matrix(c(
     420, 420, 480, 480, 600, 780,
     420, 480, 480, 360, 480, 600,
     480, 480, 540, 660, 780, 780,
     420, 540, 540, 480, 780, 900,
     540, 660, 540, 480, 660, 720,
     360, 420, 360, 360, 480, 540,
     480, 480, 600, 540, 720, 840,
     480, 600, 660, 540, 720, 900,
     540, 600, 540, 480, 720, 780,
     480, 420, 540, 540, 660, 780),
     ncol = 6, byrow = TRUE,
     dimnames=list(subj=1:10,
                   cond=c("deg0NA", "deg4NA", "deg8NA",
                          "deg0NP", "deg4NP", "deg8NP")))

     mlmfit <- lm(reacttime~1)
     SSD(mlmfit)
     estVar(mlmfit)

