Internal functions used by `trainTree` in the various steps of the algorithm. These functions are not intended for direct use by end users and are primarily for internal logic and calculations within the package.
This internal function calculates the optimal treatment based on patient sensitivity data.
This internal function calculates the optimal split point based on a specified gene in the expression data.
This internal function calculates the summed IC50 value based on the response of patients to a specific gene.
This internal function identifies the optimal split point in expression data based on patient sensitivity (IC50).
This internal function recursively builds a decision tree based on expression data and patient sensitivity (IC50).
This internal function identifies the optimal split point in a mutation matrix based on patient sensitivity data (IC50) and the presence of specific mutations.
This internal function recursively builds a decision tree based on patient data and drug sensitivity responses, specifically designed for mutation data.
getTreatment(PatientSensitivity, weights)getSplit(gene, PatientData, PatientSensitivity)
getsumic50v3(genePatientResponse, PatientSensitivity)
findsplitExp(
PatientSensitivity,
PatientData,
minimum = 1,
weights = NULL,
verbose = FALSE
)
growtreeExp(
id = 1L,
PatientSensitivity,
PatientData,
minbucket = 10,
weights = NULL
)
findsplitMut(PatientSensitivity, X, minimum = 1, weights)
growtreeMut(
id = 1L,
PatientSensitivity,
PatientData,
minbucket = 10,
weights = NULL,
findsplit = findsplitMut
)
A list of internal outputs generated by these functions.
An integer indicating the index of the optimal treatment based on the minimum sum of sensitivity values.
A list containing: - `sumic50`: The minimum summed IC50 values for the two groups. - `Treatment1`: The treatment associated with the first group. - `Treatment2`: The treatment associated with the second group. - `split`: The index of the optimal split point. - `expressionSplit`: The expression value at the split point adjusted by a small epsilon.
A numeric value representing the minimum summed IC50 value derived from the patient responses.
A `partysplit` object representing the optimal split based on the specified patient sensitivity and expression data.
A `partynode` object representing the current node and its children in the decision tree.
A `partysplit` object if a valid split is found, or `NULL` if no valid split can be determined.
A `partynode` object representing the current node and its children in the decision tree.
A matrix representing drug response values (e.g., IC50), where rows correspond to patients/samples and columns correspond to drugs.
A numeric vector indicating which samples are under study; defaults to NULL, meaning all samples are considered.
The index of the gene used for splitting the data.
A matrix representing patient features, where rows correspond to patients/samples and columns correspond to genes/features.
A numeric vector representing the response of patients to a particular gene.
An integer specifying the minimum number of samples required for a valid split (default is 1).
A logical value indicating whether to print additional information during execution (default is FALSE).
A unique identifier for the node in the decision tree (default is 1L).
An integer specifying the minimum number of samples required in a child node for further splitting (default is 10).
(PatientData) A matrix representing patient features, where rows correspond to patients/samples and columns correspond to genes/features.
A function used to find the best split; defaults to `findsplitMut`.