presCall-methods             package:xps             R Documentation

_G_e_t/_S_e_t _P_r_e_s_e_n_t _C_a_l_l _V_a_l_u_e_s

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

     Get/set present call values from/for class 'CallTreeSet'.

     _Usage_

     'presCall(object)' 
      'presCall(object, treenames = NULL) <- value' 

      'pvalData(object)' 
      'pvalData(object, treenames = NULL) <- value'

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

  object: object of class 'CallTreeSet'.

treenames: 'character' vector containing optional tree names to be used
          as subset.

   value: 'data.frame' containing present call values.

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

     Get the p-values from slot 'data' or present calls from slot
     'detcall', or set slot 'data' or 'detcall', respectively, to
     'value'.

     Method 'presCall' returns the present calls from slot 'detcall' as
     'data.frame', while replacement method 'presCall<-' allows to
     replace slot 'detcall' with a 'data.frame'.

     Method 'pvalData' returns the p-values from slot 'data' as
     'data.frame', while replacement method 'pvalData<-' allows to
     replace slot 'data' with a 'data.frame'.

     In order to create an 'CallTreeSet' containing only a subset of
     e.g. slot 'data', first export slot 'data' using method
     'pvalData', create a 'character' vector containing only
     'treenames' to be used in the subset, and then use replacement
     method 'pvalData<-' to replace slot 'data' with the subset. Slots
     'treenames' and 'numtrees' will be updated automatically for
     'pvalData<-' but not for 'presCall<-'.

     Note: When creating 'character' vector 'treenames' it is
     sufficient to use the name part of the tree name w/o the
     extension.

     Note: If you do not want to replace your current object, create
     first a copy of type 'CallTreeSet' by simply writing 'newobj <-
     oldobj', and use 'newobj' for replacement.

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

     Christian Stratowa

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

     'exprs'

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

     ## Not run: 
     ## load ROOT scheme file and ROOT data file
     scheme.test3 <- root.scheme(paste(.path.package("xps"),"schemes/SchemeTest3.root",sep="/"))
     data.test3 <- root.data(scheme.test3, paste(.path.package("xps"),"rootdata/DataTest3_cel.root",sep="/"))

     ## create an CallTreeSet
     call.mas5 <- mas5.call(data.test3,"tmp_TestMAS5Call",tmpdir="",verbose=FALSE)

     ## get p-values
     value <- pvalData(call.mas5)

     ## selected treenames only
     treenames <- c("TestA2", "TestB1")

     ## make a copy of your object if you do not want to replace it
     subset.call <- call.mas5

     ## replace slot data with subset
     exprs(subset.call, treenames) <- value
     str(subset.call)
     ## End(Not run)

