TopoS                  package:klaR                  R Documentation

_C_o_m_p_u_t_a_t_i_o_n _o_f _c_r_i_t_e_r_i_o_n _S _o_f _a _v_i_s_u_a_l_i_z_a_t_i_o_n

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

     'TopoS' computes one version of the criterion 'stress' as i.e. 
     known from 'sammon' for a given visualization.

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

     TopoS(EV.dist, Cells.dist)

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

 EV.dist: a symmetric distance matrix consisting of distances in the
          origin space ('dx')

Cells.dist: a symmetric distance matrix consisting of distances in the
          target space ('dy')

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

     TopoS first performs a homogeneous linear regression where 'dx' is
     predicted by 'dy'.  Then the residual sum of squares of this
     regression is computed and divided by the sum of squared 'dx'. 
     Finally one minus the square root of the latter result defines
     'S'.

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

     'TopoS' returns a numeric between zero and one which is the
     criterion 'S' of the given visualization.

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

     Nils Raabe

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

     'EDAM'

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

     # Compute S for the MDS visualization of the german business data
     data(B3)
     plot(cmdscale(dist(B3[, 2:14])), col = rainbow(4)[B3[, 1]], pch = 16)
     TopoS(dist(B3[, 2:14]), dist(cmdscale(dist(B3[, 2:14]))))

