| phenoage_calc | R Documentation | 
Project Phenotypic Age algorithm onto new data.
phenoage_calc(data, biomarkers, fit = NULL, orig = FALSE)
| data | A projection dataset. | 
| biomarkers | A character vector indicating the names of the biomarkers included in the Phenotypic Age algorithm. | 
| fit | An S3 object for model fit. If the value is NULL, then the parameters to use for training Phenotypic Age are calculated. | 
| orig | TRUE to compute the origianl Phenotypic Age. | 
Projecting Phenotypic Age algorithm onto new data.
An object of class "phenoage". This object is a list with two elements (data and fit). The dataset can be drawn by typing 'data'. The model can be drawn by typing 'fit'.
#Train using the NHANES III
train = phenoage_calc(NHANES3,
                      biomarkers = c("albumin_gL","lymph","mcv","glucose_mmol",
                      "rdw","creat_umol","lncrp","alp","wbc"))
#Project into the NHANES IV
phenoage = phenoage_calc(NHANES4,
                         biomarkers = c("albumin_gL","lymph","mcv","glucose_mmol",
                         "rdw","creat_umol","lncrp","alp","wbc"),
                         fit = train$fit)
#Extract phenoage dataset
data = phenoage$data
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.