msc               package:pls               R Documentation(latin1)

_M_u_l_t_i_p_l_i_c_a_t_i_v_e _S_c_a_t_t_e_r _C_o_r_r_e_c_t_i_o_n

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

     Performs multiplicative scatter/signal correction on a data
     matrix.

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

     msc(X, reference = NULL)
     ## S3 method for class 'msc':
     predict(object, newdata, ...)
     ## S3 method for class 'msc':
     makepredictcall(var, call)

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

X, newdata: numeric matrices.  The data to scatter correct.

reference: numeric vector.  Spectre to use as reference.  If 'NULL',
          the column means of 'X' are used.

  object: an object inheriting from class '"msc"', normally the result
          of a call to 'msc' with a single matrix argument.

     var: A variable.

    call: The term in the formula, as a call.

     ...: other arguments.  Currently ignored.

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

     'makepredictcall.msc' is an internal utility function; it is not
     meant for interactive use.  See 'makepredictcall' for details.

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

     Both 'msc' and 'predict.msc' return a multiplicative scatter
     corrected matrix, with attribute '"reference"' the vector used as
     reference spectre. The matrix is given class 'c("msc", "matrix")'.
      For 'predict.msc', the '"reference"' attribute of 'object' is
     used as reference spectre.

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

     Bjrn-Helge Mevik and Ron Wehrens

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

     Martens, H., Ns, T. (1989) _Multivariate calibration._
     Chichester: Wiley.

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

     'mvr', 'pcr', 'plsr', 'stdize'

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

     data(yarn)
     ## Direct correction:
     Ztrain <- msc(yarn$NIR[yarn$train,])
     Ztest <- predict(Ztrain, yarn$NIR[!yarn$train,])

     ## Used in formula:
     mod <- plsr(density ~ msc(NIR), ncomp = 6, data = yarn[yarn$train,])
     pred <- predict(mod, newdata = yarn[!yarn$train,]) # Automatically scatter corrected

