robustCorr            package:maigesPack            R Documentation

_C_a_l_c_u_l_a_t_e _a _r_o_b_u_s_t _c_o_r_r_e_l_a_t_i_o_n _v_a_l_u_e

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

     This function is intended to calculate robust correlation values
     between pairs of rows of numerical matrix or between two numerical
     vectors.

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

     robustCorr(x, y=NULL)

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

       x: numerical matrix or vector. If a matrix the method calculates
          the robust correlations between all pairs of rows. If 'x' is
          a vector, 'y' must be specified as another vector of same
          length as 'x' and the robust correlation between them is
          calculate.

       y: optional numeric vector, must be specified if 'x' is a
          vector.

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

     This function calculates a robust correlation value in a procedure
     similar to the leave-one-out used for cross-validation of
     classification results. The algorithm removes one point at a time
     and calculates a usual Pearson correlation value. Them, with a
     vector '\bold{r}' of correlation values that has the same length
     as the columns of 'x' (or vectors 'x' and 'y'), the algorithm
     decides by the 'min'(*r*) or 'max'(*r*), according with that one
     that is more distant from the median value.

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

     If 'x' is a matrix, the method return a list with two square
     matrices, the first one containing the robust correlation values
     between all pairs of rows from 'x' and the second containing the
     index of the point removed from calculation. If 'x' is a vector,
     'y' must be specified and the function return a list with the
     robust correlation value between them and the index of the point
     removed.

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

     Gustavo H. Esteves <gesteves@vision.ime.usp.br>

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

     'cor' from package _stats_.

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

     x <- runif(50, 0, 1)
     y <- rbeta(50, 1, 2)
     robustCorr(x, y)

     z <- matrix(rnorm(100, 0, 1), 4, 25)
     robustCorr(z)

