vsn2trsf                 package:vsn                 R Documentation

_A_p_p_l_y _t_h_e _v_s_n _t_r_a_n_s_f_o_r_m_a_t_i_o_n _t_o _d_a_t_a

_D_e_s_c_r_i_p_t_i_o_n:

     Apply the vsn transformation to data.

_U_s_a_g_e:

     ## S4 method for signature 'vsn':
     predict(object, newdata, strata=object@strata, log2scale=TRUE, useDataInFit=FALSE)

_A_r_g_u_m_e_n_t_s:

  object: An object of class 'vsn' that contains transformation
          parameters and strata information, typically this is the
          result of a previous call to 'vsn2'.

 newdata: Object of class 'ExpressionSet', 'NChannelSet', 'AffyBatch'
          (from the 'affy' package), 'RGList' (from the 'limma'
          package), 'matrix' or 'numeric', with the data to which the
          fit is to be applied to.

  strata: Optional, a 'factor' or 'integer' that aligns with the rows
          of 'newdata'; see the 'strata' argument of 'vsn2'.

log2scale: If 'TRUE', the data are returned on the glog scale to base
          2, and an overall offset c is added (see _Value_ section of
          the 'vsn2' manual page). If 'FALSE', the data are returned on
          the glog scale to base e, and no offset is added.

useDataInFit: If 'TRUE', then no transformation is attempted and the
          data stored in 'object' is transferred appropriately into
          resulting object, which otherwise preserves the class and
          metadata of 'newdata'. This option exists to increase
          performance in constructs like


                 fit = vsn2(x, ...)
                 nx = predict(fit, newdata=x)

          and is used, for example, in the 'justvsn' function. 

_V_a_l_u_e:

     An object typically of the same class as 'newdata'. There are two
     exceptions: if 'newdata' is an 'RGList', the return value is an
     'NChannelSet', and if 'newdata' is numeric, the return value is a
     'matrix' with 1 column.

_A_u_t_h_o_r(_s):

     Wolfgang Huber <URL: http://www.ebi.ac.uk/huber>

_E_x_a_m_p_l_e_s:

     data("kidney")

     ## nb: for random subsampling, the 'subsample' argument of vsn
     ##   provides an easier way to do this
     fit = vsn2(kidney[sample(nrow(kidney), 500), ])
     tn = predict(fit, newdata=exprs(kidney))

