Calculate actual interaction values between two terms in a data frame.
calculate_actual_interactionX2_values.Rd
This function calculates the actual interaction values between two terms, lbl_term_1
and lbl_term_2
,
in the given data frame data
. The interaction values are computed based on the mean log expression levels
of the conditions satisfying the specified term combinations, and also considering a reference condition.
Usage
calculate_actual_interactionX2_values(
data,
l_reference,
clmn_term_1,
lbl_term_1,
clmn_term_2,
lbl_term_2
)
Arguments
- data
A data frame containing the expression data and associated terms.
- l_reference
A data frame representing the reference condition for the interaction.
- clmn_term_1
The name of the column in
data
representing the first term.- lbl_term_1
The label of the first term to compute interactions for.
- clmn_term_2
The name of the column in
data
representing the second term.- lbl_term_2
The label of the second term to compute interactions for.
Examples
average_gt <- data.frame(clmn_term_1 = c("A", "A", "B", "B"),
clmn_term_2 = c("X", "Y", "Y", "X"),
logQij_mean = c(1.5, 8.0, 0.5, 4.0))
# Définir les paramètres de la fonction
l_label <- list(clmn_term_1 = c("A", "B"), clmn_term_2 = c("X", "Y"))
clmn_term_1 <- "clmn_term_1"
lbl_term_1 <- "B"
clmn_term_2 <- "clmn_term_2"
lbl_term_2 <- "Y"
# Calculer la valeur d'interaction réelle
actual_interaction <- calculate_actual_interactionX2_values(average_gt,
l_label, clmn_term_1, lbl_term_1,
clmn_term_2, lbl_term_2)