koplsPlotSensSpec           package:kopls           R Documentation

_P_l_o_t_s _s_e_n_s_i_t_i_v_i_t_y _a_n_d _s_p_e_c_i_f_i_c_i_t_y _r_e_s_u_l_t_s _f_r_o_m _c_r_o_s_s-_v_a_l_i_d_a_t_i_o_n

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

     Plots sensitivity and specificity results from cross-validation in
     a bar plot. The produced bars are shown separately for each class
     including overall sensitivity and specificity results.

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

     koplsPlotSensSpec(modelFull)

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

modelFull: The 'koplscv' model from cross-validation (see 'koplsCV').

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

     The resulting sensitivity and specificity measures.

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

     Max Bylesjo and Mattias Rantalainen

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

     Rantalainen M, Bylesjo M, Cloarec O, Nicholson JK, Holmes E and
     Trygg J. *Kernel-based orthogonal projections to latent structures
     (K-OPLS)*, _J Chemometrics_ 2007; 21:376-385.
     doi:10.1002/cem.1071.

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

     ## Load data set
     data(koplsExample)

     ## Define kernel function parameter
     sigma<-25 

     ## Construct kernel
     Ktr<-koplsKernel(Xtr,NULL,'g',sigma)

     ## Find optimal number of Y-orthogonal components by cross-validation
     ## The cross-validation tests models with Y-orthogonal components 0 through numYo
     modelCV<-koplsCV(Ktr,Ytr,1,3,nrcv=7,cvType='nfold',preProcK='mc',preProcY='mc',modelType='da')

     ## Visualize results
     koplsPlotSensSpec(modelCV)

