trainTree | R Documentation |
This function trains a decision tree model based on patient data, which can either be gene expression levels or a binary matrix indicating mutations.
trainTree(PatientData, PatientSensitivity, minbucket = 20)
PatientData |
A matrix representing patient features, where rows correspond to patients/samples and columns correspond to genes/features. This matrix can contain:
|
PatientSensitivity |
A matrix representing drug response values, where rows correspond to patients in the same order as in 'PatientData', and columns correspond to drugs. Higher values indicate greater drug resistance and, consequently, lower sensitivity to treatment. This matrix can represent various measures of drug response, such as IC50 values or area under the drug response curve (AUC). Depending on the interpretation of these values, users may need to adjust the sign of this data. |
minbucket |
An integer specifying the minimum number of patients required in a node to allow for a split. |
An object of class 'party' representing the trained decision tree, with the assigned treatments for each node.
# Basic example of using the trainTree function with mutational data
data("drug_response_w12")
data("mutations_w12")
ODTmut <- trainTree(PatientData = mutations_w12,
PatientSensitivity = drug_response_w12,
minbucket = 10)
plot(ODTmut)
# Example using gene expression data instead
data("drug_response_w34")
data("expression_w34")
ODTExp <- trainTree(PatientData = expression_w34,
PatientSensitivity = drug_response_w34,
minbucket = 20)
plot(ODTExp)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.