get_pheno | R Documentation |
This function can return a number of different trait matrices depending on the arguments.
get_pheno( data_obj, scan_what = c("eigentraits", "normalized_traits", "raw_traits"), covar = NULL )
data_obj |
a |
scan_what |
A character string. One of "eigentraits", "normalized.trait", or "raw_traits." If "eigentraits" the function returns the eigentraits matrix. If "normalized_traits" the function returns the trait matrix after mean-centering and normalizing. If "raw.trait" the function returns the trait matrix before mean-centering and normalization were applied. |
covar |
A character value indicating which, if any, covariates the traits should be adjusted for. If covariates are specified, the function fits a linear model to specify the traits with the covariates and returns the matrix of residuals (i.e. the traits after adjusting for the covariates). |
A matrix in which each column is a trait, and each row is an individual. The values correspond to the argument settings described above.
## Not run: #get eigentrait matrix eigenT <- get_pheno(data_obj, "eigentraits") #get normalized trait matrix pheno <- get_pheno(data_obj, "normalized_traits") #get normalized traits adjusted for sex pheno <- get_pheno(data_obj, "normalized_traits", covar = "sex") #get raw trait matrix pheno <- get_pheno(data_obj, "raw_traits") ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.