GVH POSACONAZOLE
-
COHORTE ONCOPOLE

1- PACKAGES

1- 1 Installation packages nécessaires

install.packages(“tidyverse”) install.packages(“dplyr”) install.packages(“gtsummary”) install.packages(“readxl”) install.packages(“car”) install.packages(“broom.helpers”) install.packages(“ResourceSelection”) install.packages(“ggstats”) install.packages(“plotROC”) install.packages(“caret”) install.packages(“rms”) install.packages(“pROC”) install.packages(“boot”) install.packages(“ggalluvial”) install.packages(“knitr”) install.packages(“rlang”)

1- 2 Chargement des libraries

library(tidyverse) library(dplyr) library(gtsummary) library(readxl) library(broom.helpers) library(car) library(ResourceSelection) library(ggstats) library(plotROC) library(caret) library(rms) library(pROC) library(boot) library(ggalluvial) library(knitr) library(rlang)

2- IMPORT DATABASE

database <- read_excel(“L:/Travaux de fond/Stats/GVH posaconazole/Recueil de données/database.xlsx”)

View(database)

3 - VARIABLES QUANTITATIVES - DEFINITION DISTRIBUTION ET TESTS

3 - 1 Age

Distribution: visualisation graphique

distribution_age <- ggplot(database, aes(x = Age)) + geom_histogram(aes(y = after_stat(density)), color = “#000000”, fill = “#0099F8”) + geom_density(color = “#000000”, fill = “#F85700”, alpha = 0.6)+ theme_classic()+ labs( title = “Histogram of age distribution”, subtitle = “N total = 24”, x = “Age (years)”, y = “Density (%)” ) distribution_age

Test de Normalité Shapiro-Wilk

shapiro.test_age <- shapiro.test(database$Age) shapiro.test_age

p<0.05 donc ne suit pas une loi normale

3 - 2 Albuminémie avant GVH

Distribution: visualisation graphique

distribution_albumine_avant <- ggplot(database, aes(x = Albuminémie avant GVH)) + geom_histogram(aes(y = after_stat(density)), color = “#000000”, fill = “#0099F8”) + geom_density(color = “#000000”, fill = “#F85700”, alpha = 0.6)+ theme_classic()+ labs( title = “Histogram of albuminemia before distribution”, subtitle = “N total = 24”, x = “Albuminémie avant GVH”, y = “Density (%)” ) distribution_albumine_avant

Test de Normalité Shapiro-Wilk

shapiro.test_albumine_avant <- shapiro.test(database$Albuminémie avant GVH) shapiro.test_albumine_avant

p>0.05 donc suit une loi normale

3 - 3 Albuminémie après GVH

Distribution: visualisation graphique

distribution_albumine_après <- ggplot(database, aes(x = Albuminémie après GVH)) + geom_histogram(aes(y = after_stat(density)), color = “#000000”, fill = “#0099F8”) + geom_density(color = “#000000”, fill = “#F85700”, alpha = 0.6)+ theme_classic()+ labs( title = “Histogram of albuminemia after distribution”, subtitle = “N total = 24”, x = “Albuminémie après GVH”, y = “Density (%)” ) distribution_albumine_après

Test de Normalité Shapiro-Wilk

shapiro.test_albumine_après <- shapiro.test(database$Albuminémie après GVH) shapiro.test_albumine_après

p>0.05 donc suit une loi normale

4 - VARIABLES QUALITATIVES - DEFINITION MODALITES ET TESTS

4 - 1 Sexe

database <- database %>% mutate( Sexe = case_when( Sexe == “m” ~ “Masculin”, Sexe == “f” ~ “Féminin” ), Sexe = factor(Sexe, levels = c(“Féminin”, “Masculin”)) )

4 - 2 Origine cellules sources - factorisation nominal

database <- database %>% mutate( Origine cellules sources = factor(Origine cellules sources) )

4 - 3 Conditionnement - factorisation nominal

database <- database %>% mutate( Conditionnement = factor(Conditionnement) )

4 - 4 Localisation GVH

database <- database %>% mutate( Localisation GVH = factor( Localisation GVH, levels = c(0, 1, 2), labels = c(“Localisation basse”, “Localisation haute”, “Localisation haute et basse”) ))

4 - 5 Grade

database <- database %>% mutate(Grade GVH = case_when( Grade GVH %in% c(1, 2) ~ “Grade I-II”, Grade GVH %in% c(3, 4) ~ “Grade III-IV”, TRUE ~ NA_character_ ), Grade GVH = factor(Grade GVH, levels = c(“Grade I-II”, “Grade III-IV”)) )

5 - STATISTIQUES DESCRIPTIVES

table_1 <- database %>% tbl_summary( include = c(Sexe, Age, Localisation GVH, Origine cellules sources, Conditionnement, Albuminémie avant GVH, Albuminémie après GVH, Différentiel albuminémie avant/après GVH, Résiduel posaconazole avant GVH, Résiduel posaconazole après GVH, Différentiel résiduel posaconazole avant/après GVH), statistic = list( Age ~ “{median} [{p25} - {p75}]”, Albuminémie avant GVH ~ “{mean} ± {sd}”, Albuminémie après GVH ~ “{mean} ± {sd}”, Différentiel albuminémie avant/après GVH ~ “{mean} ± {sd}”, Résiduel posaconazole avant GVH ~ “{mean} ± {sd}”, Résiduel posaconazole après GVH ~ “{mean} ± {sd}”, Différentiel résiduel posaconazole avant/après GVH ~ “{mean} ± {sd}”, all_categorical() ~ “{n} ({p}%)” ), label = list( Sexe ~ “Sexe”, Age ~ “Age (années), médiane [intervalle IQ]”, Localisation GVH ~ “Localisation GVH”, Origine cellules sources ~ “Origine cellules sources”, Conditionnement ~ “Conditionnement”, Albuminémie avant GVH ~ “Albuminémie avant GVH (g/L), moyenne ± ET”, Albuminémie après GVH ~ “Albuminémie après GVH (g/L), moyenne ± ET”, Différentiel albuminémie avant/après GVH ~ “Différentiel albuminémie, moyenne ± ET”, Résiduel posaconazole avant GVH ~ “Résiduel posaconazole avant GVH, moyenne ± ET”, Résiduel posaconazole après GVH ~ “Résiduel posaconazole après GVH, moyenne ± ET”, Différentiel résiduel posaconazole avant/après GVH ~ “Différentiel résiduel posaconazole, moyenne ± ET” ), missing = “no” ) %>% as_gt() %>% gt::fmt_markdown(columns = label) %>% gt::tab_header( title = gt::html(“Tableau 1 : Caractéristiques de la population étudiée traitée par posaconazole”) )

table_1

6 - ANALYSES INFERENTIELLES: COMPARAISON AVANT/APRES GVH

6 - 1 Concentration résiduelle en posaconazole avant/après GVH

Test de Student apparié |> distributions normales (cf. shapiro.test_resi_posaco_avant

et shapiro.test_resi_posaco_après, p>0.05), condition de validité remplie = distribution symétrique

t.test_posaco <- t.test(database\(`Résiduel posaconazole avant GVH`, database\)Résiduel posaconazole après GVH, paired = TRUE) t.test_posaco

p = 0.012, différence significative, résiduelle posaconazole plus bas après GVH

6 - 2 Albuminémie avant/après GVH

Test des rangs signés de Wilcoxon apparié (choix conservateur, sans hypothèse

de normalité, malgré shapiro.test_albumine_avant/après non significatifs)

wilcox.test_albumine <- wilcox.test(database\(`Albuminémie avant GVH`, database\)Albuminémie après GVH, paired = TRUE) wilcox.test_albumine

p = 0.069, pas de différence significative (tendance à la baisse non confirmée)

7 - ANALYSE BIVARIEE : DIFFERENTIEL POSACONAZOLE ~ CARACTERISTIQUES GVH

7 - 1 Différentiel posaconazole ~ Grade GVH (2 groupes)

Verification des conditions de validite : normalite intra-groupe + homoscedasticite

shapiro.test_diffposo_grade12 <- shapiro.test( database\(`Différentiel résiduel posaconazole avant/après GVH`[database\)Grade GVH == “Grade I-II”]) shapiro.test_diffposo_grade12

p>0.05, distribution normale dans le groupe Grade I-II

shapiro.test_diffposo_grade34 <- shapiro.test( database\(`Différentiel résiduel posaconazole avant/après GVH`[database\)Grade GVH == “Grade III-IV”]) shapiro.test_diffposo_grade34

p>0.05, distribution normale dans le groupe Grade III-IV

Ratio des ecarts-types (doit etre entre 0.7 et 1.4 pour Student classique) :

sd_grade12 <- sd(database\(`Différentiel résiduel posaconazole avant/après GVH`[database\)Grade GVH == “Grade I-II”]) sd_grade34 <- sd(database\(`Différentiel résiduel posaconazole avant/après GVH`[database\)Grade GVH == “Grade III-IV”]) sd_grade12 / sd_grade34 # ratio = 1.19, homoscedasticite -> Student classique (sans correction de Welch)

Test de Student pour echantillons independants

t.test_diffposo_grade <- t.test( database\(`Différentiel résiduel posaconazole avant/après GVH` ~ database\)Grade GVH, var.equal = TRUE) t.test_diffposo_grade

p = 0.432, pas de difference significative du differentiel posaconazole

selon le grade de la GVH (1-2 vs 3-4)

7 - 2 Différentiel posaconazole ~ Localisation GVH (3 groupes)

Verification des conditions de validite : normalite intra-groupe + homoscedasticite

shapiro.test_diffposo_basse <- shapiro.test( database\(`Différentiel résiduel posaconazole avant/après GVH`[database\)Localisation GVH == “Localisation basse”]) shapiro.test_diffposo_haute <- shapiro.test( database\(`Différentiel résiduel posaconazole avant/après GVH`[database\)Localisation GVH == “Localisation haute”]) shapiro.test_diffposo_bassehaute <- shapiro.test( database\(`Différentiel résiduel posaconazole avant/après GVH`[database\)Localisation GVH == “Localisation haute et basse”]) shapiro.test_diffposo_basse shapiro.test_diffposo_haute shapiro.test_diffposo_bassehaute # p>0.05 dans les 3 sous-groupes -> distributions normales # (NB : sous-groupes tres petits, n=5 et n=6 -> puissance faible pour detecter un ecart)

Ratio des ecarts-types (max/min) entre les 3 groupes :

sds_loc <- tapply(database\(`Différentiel résiduel posaconazole avant/après GVH`, database\)Localisation GVH, sd) max(sds_loc) / min(sds_loc) # ratio = 2.33, hors de l’intervalle 0.7-1.4 -> heteroscedasticite -> ANOVA avec correction de Welch

ANOVA avec correction de Welch var.equal=FALSE

anova.test_diffposo_localisation <- oneway.test( database\(`Différentiel résiduel posaconazole avant/après GVH` ~ database\)Localisation GVH, var.equal = FALSE) anova.test_diffposo_localisation

p = 0.0078, difference significative du differentiel posaconazole

selon la localisation de la GVH

Verification par un test non-parametrique (Kruskal-Wallis), sans hypothese

de normalite, pour confirmer la robustesse du resultat

kruskal.test_diffposo_localisation <- kruskal.test( database\(`Différentiel résiduel posaconazole avant/après GVH` ~ database\)Localisation GVH) kruskal.test_diffposo_localisation

p = 0.0167, resultat concordant avec l’ANOVA de Welch -> conclusion robuste

Tests post-hoc deux-a-deux (Student, non apparies), avec correction de

Bonferroni : seuil de significativite = 0.05 / 3 comparaisons = 0.0167

t.test_posthoc_basse_haute <- t.test( database\(`Différentiel résiduel posaconazole avant/après GVH`[database\)Localisation GVH == “Localisation basse”], database\(`Différentiel résiduel posaconazole avant/après GVH`[database\)Localisation GVH == “Localisation haute”])

t.test_posthoc_basse_bassehaute <- t.test( database\(`Différentiel résiduel posaconazole avant/après GVH`[database\)Localisation GVH == “Localisation basse”], database\(`Différentiel résiduel posaconazole avant/après GVH`[database\)Localisation GVH == “Localisation haute et basse”])

t.test_posthoc_haute_bassehaute <- t.test( database\(`Différentiel résiduel posaconazole avant/après GVH`[database\)Localisation GVH == “Localisation haute”], database\(`Différentiel résiduel posaconazole avant/après GVH`[database\)Localisation GVH == “Localisation haute et basse”])

t.test_posthoc_basse_haute # p = 0.075 -> non significatif apres Bonferroni t.test_posthoc_basse_bassehaute # p = 0.087 -> non significatif apres Bonferroni t.test_posthoc_haute_bassehaute # p = 0.0058 -> SIGNIFICATIF apres Bonferroni

Conclusion : la difference globale est principalement portee par l’opposition

#localisation haute” vs “localisation haute et basse” -> la localisation haute et basse combinée #est associée à une diminution plus marquée du résiduel posaconazole après GVH, comparativement #à la localisation haute isolée qui tend au contraire vers une augmentation (rappel: différentiel = (avant - après/avant))

7 - 3 Tableau recapitulatif

Tableau 2a : selon le Grade GVH (test de Student, ecarts-types homogenes

ratio=1.19, cf. section 7-1)

tbl_bivar_grade <- database %>% tbl_summary( by = Grade GVH, include = Différentiel résiduel posaconazole avant/après GVH, statistic = all_continuous() ~ “{mean} ± {sd}”, label = Différentiel résiduel posaconazole avant/après GVH ~ “Différentiel résiduel posaconazole” ) %>% add_p(test = everything() ~ “t.test”) %>% bold_labels() %>% modify_caption(“Tableau 2a. Différentiel résiduel posaconazole selon le Grade GVH (test de Student)”)

tbl_bivar_grade

Tableau 2b : selon la Localisation GVH (test de Kruskal-Wallis retenu en

test principal + test secondaire ANOVA avec correction de Welch

tbl_bivar_localisation <- database %>% tbl_summary( by = Localisation GVH, include = Différentiel résiduel posaconazole avant/après GVH, statistic = all_continuous() ~ “{mean} ± {sd}”, label = Différentiel résiduel posaconazole avant/après GVH ~ “Différentiel résiduel posaconazole” ) %>% add_p(test = everything() ~ “kruskal.test”) %>% bold_labels() %>% modify_caption(“Tableau 2b. Différentiel résiduel posaconazole selon la Localisation GVH (test de Kruskal-Wallis)”) %>% modify_source_note( “Résultat concordant avec l’ANOVA de Welch (p = 0,0078). Test post-hoc (Student, correction de Bonferroni, seuil = 0,05/3) : différence significative uniquement entre Localisation haute et Localisation haute+basse (p = 0,0058) ; les autres comparaisons deux-à-deux ne sont pas significatives.” )

tbl_bivar_localisation

8 - DIAGRAMME SANKEY : GRADE -> LOCALISATION -> EVOLUTION POSACONAZOLE

8 - 1 Construction de la variable “Evolution du residuel posaconazole”

(differentiel > 0 = le residuel a diminue apres la GVH ;

differentiel < 0 = le residuel a augmente apres la GVH)

database <- database %>% mutate(Evolution résiduel posaconazole = case_when( Différentiel résiduel posaconazole avant/après GVH > 0 ~ “Diminution après GVH”, Différentiel résiduel posaconazole avant/après GVH < 0 ~ “Augmentation après GVH” ), Evolution résiduel posaconazole = factor(Evolution résiduel posaconazole, levels = c(“Diminution après GVH”, “Augmentation après GVH”)))

8 - 2 Mise en forme des donnees pour le sankey

data_alluvial <- database %>% count(Grade GVH, Localisation GVH, Evolution résiduel posaconazole, name = “Effectif”)

8 - 3 Construction du modèle

sankey_grade_localisation_sens <- ggplot(data_alluvial, aes(axis1 = Grade GVH, axis2 = Localisation GVH, axis3 = Evolution résiduel posaconazole, y = Effectif)) + geom_alluvium(aes(fill = Grade GVH), width = 1/4, alpha = 0.8, color = “grey30”, linewidth = 0.25) + geom_stratum(width = 1/4, fill = “grey90”, color = “black”) + geom_text(stat = “stratum”, aes(label = paste0(after_stat(stratum), “=”, after_stat(count), ” (“, round(100 * after_stat(count) / 24),”%)“)), size = 2.6) + scale_x_discrete(limits = c(”Grade GVH”, “Localisation GVH”, “Evolution résiduel posaconazole”), expand = c(0.12, 0.12)) + theme_classic() + theme(legend.position = “none”) + labs( title = “Diagramme de Sankey explorant la relation: grade de la GVH, localisation de la GVH et évolution de résiduelle de posaconazole”, subtitle = “N total = 24”, x = ““, y =”Effectif” )

sankey_grade_localisation_sens

9 - REGRESSION LINEAIRE : DIFFERENTIEL RESIDUEL POSACONAZOLE

Conditions de realisation / n = 24 / jusqu’a 7 variables explicatives candidates

-> a n=24, la regle usuelle (~10 individus par parametre estime) interdit

d’entrer plus de 2-3 parametres dans le modele multivarie.

Sexe

lm_sexe <- lm(Différentiel résiduel posaconazole avant/après GVH ~ Sexe, data = database)

Age

lm_age <- lm(Différentiel résiduel posaconazole avant/après GVH ~ Age, data = database)

Grade GVH

lm_grade <- lm(Différentiel résiduel posaconazole avant/après GVH ~ Grade GVH, data = database)

Localisation GVH

lm_localisation <- lm(Différentiel résiduel posaconazole avant/après GVH ~ Localisation GVH, data = database)

Origine cellules sources

lm_origine <- lm(Différentiel résiduel posaconazole avant/après GVH ~ Origine cellules sources, data = database)

Conditionnement

lm_conditionnement <- lm(Différentiel résiduel posaconazole avant/après GVH ~ Conditionnement, data = database)

Albuminémie avant GVH (uniquement la valeur avant : celle d’apres est

potentiellement elle-meme affectee par la GVH, donc pas un vrai facteur

explicatif de base)

lm_albumine_avant <- lm(Différentiel résiduel posaconazole avant/après GVH ~ Albuminémie avant GVH, data = database)

9 - 2 Table des regressions univariables (modele “crude”), avec p-value

globale par variable (add_global_p, indispensable pour les variables a

plus de 2 modalites comme Localisation GVH)

tbl_uni_diffposo <- database %>% tbl_uvregression( method = lm, y = Différentiel résiduel posaconazole avant/après GVH, include = c(Sexe, Age, Grade GVH, Localisation GVH, Origine cellules sources, Conditionnement, Albuminémie avant GVH)) %>% add_global_p()

tbl_uni_diffposo

Seule la Localisation GVH est associee en univarie (p global = 0.038,

test F de type III) ; toutes les autres variables sont non significatives

(p = 0.31 a 0.63)

9 - 3 Modele multivarie : Localisation GVH + Grade GVH

Colinearite des variables explicatives

lm_model_diffposo <- lm( Différentiel résiduel posaconazole avant/après GVH ~ Localisation GVH + Grade GVH, data = database)

vif(lm_model_diffposo) # VIF ~ 1 pour les deux -> pas de colinearite

tbl_regression(lm_model_diffposo) %>% add_global_p()

AIC(lm_localisation, lm_model_diffposo)

Le Grade GVH n’apporte rien au modele (AIC 39.3 -> 40.9, p global du

modele 0.038 -> 0.080) : la Localisation GVH reste le seul predicteur

robuste du differentiel posaconazole sur cette cohorte

9 - 4 Uniformisation des resultats crude model et adjusted model

tbl_desc_diffposo <- database %>% tbl_summary( include = c(Localisation GVH, Grade GVH), statistic = list(all_categorical() ~ “{n} ({p}%)”) )

tbl_uni_gvh <- database %>% tbl_uvregression( y = Différentiel résiduel posaconazole avant/après GVH, include = c(Localisation GVH, Grade GVH), method = lm) %>% add_global_p() %>% modify_column_hide(“stat_n”)

tbl_multi_gvh <- lm_model_diffposo %>% tbl_regression() %>% add_global_p()

table2_diffposo <- list(tbl_desc_diffposo, tbl_uni_gvh, tbl_multi_gvh) %>% tbl_merge( tab_spanner = c( NA, “Crude model”, “Adjusted model”)) %>% bold_labels()

table2_diffposo

9 - 5 Graphique des coefficients du modele multivarie

plot_lm_diffposo <- lm_model_diffposo %>% ggstats::ggcoef_table()

plot_lm_diffposo