db <- read_excel(here::here("data-raw/Dati per statistica FL.xlsx")) |>
janitor::clean_names() |>
mutate(across(c(group_1_covid_2_transplant_3_donatore,
sex_1_m_2_f,
status_vivo_1_morto_0,
ecmo_y_1_n_2,
comorbidities_1_y_1_n_0,
fibrin_y_1_n_2:fungal_infections_y_1_n_2), as.factor))
# dataReporter::makeDataReport(db,codebook = TRUE)
• Vi sono differenze di infezioni tra i tre gruppi ?
Ho creato una nuova varaibile che si chiama inf_score
che assume i valore 1
se c’è almeno una infezione, e
2
o 3
se ce ne sono più di una. Ovviamente
0
se non ce ne sono in quel paziente.
db_inf <- db |> select(group_1_covid_2_transplant_3_donatore,
bacterial_infections_y_1_n_2,
viral_infections_y_1_n_2,
fungal_infections_y_1_n_2) |>
mutate(group_1_covid_2_transplant_3_donatore = case_when(
group_1_covid_2_transplant_3_donatore == 1 ~ 'COVID',
group_1_covid_2_transplant_3_donatore == 2 ~ 'Transplant',
TRUE ~ 'Donor')) |>
mutate(inf_score = case_when(
bacterial_infections_y_1_n_2 == 1 & viral_infections_y_1_n_2 == 1 & fungal_infections_y_1_n_2 == 1 ~ 3,
bacterial_infections_y_1_n_2 == 1 & viral_infections_y_1_n_2 == 1 ~ 2,
bacterial_infections_y_1_n_2 == 1 & fungal_infections_y_1_n_2 == 1 ~ 2,
viral_infections_y_1_n_2 == 1 & fungal_infections_y_1_n_2 == 1 ~ 2,
bacterial_infections_y_1_n_2 == 1 ~ 1,
viral_infections_y_1_n_2 == 1 ~ 1,
fungal_infections_y_1_n_2 == 1 ~ 1,
TRUE ~ 0
))
t0 <- db_inf |>
tbl_summary(by = group_1_covid_2_transplant_3_donatore)
t1 <- db_inf |>
filter(group_1_covid_2_transplant_3_donatore %in% c("COVID", "Transplant")) |>
tbl_summary(by = group_1_covid_2_transplant_3_donatore) |>
add_p() |>
modify_header(p.value ~ gt::md("**COVID vs. Transplant**")) |>
# hide summary stat columns
modify_table_styling(all_stat_cols(), hide = TRUE)
t2 <- db_inf |>
filter(group_1_covid_2_transplant_3_donatore %in% c("COVID", "Donor")) |>
tbl_summary(by = group_1_covid_2_transplant_3_donatore) |>
add_p() |>
modify_header(p.value ~ gt::md("**COVID vs. Donor**")) |>
# hide summary stat columns
modify_table_styling(all_stat_cols(), hide = TRUE)
t3 <- db_inf |>
filter(group_1_covid_2_transplant_3_donatore %in% c("Transplant", "Donor")) |>
tbl_summary(by = group_1_covid_2_transplant_3_donatore) |>
add_p() |>
modify_header(p.value ~ gt::md("**Transplant vs. Donor**")) |>
# hide summary stat columns
modify_table_styling(all_stat_cols(), hide = TRUE)
t_merge <- tbl_merge(list(t0, t1, t2, t3)) %>%
modify_spanning_header(
list(
all_stat_cols() ~ "**Groups**",
starts_with("p.value") ~ "**P-values**")
)
t_merge
Characteristic | Groups | P-values | ||||
---|---|---|---|---|---|---|
COVID, N = 161 | Donor, N = 121 | Transplant, N = 121 | COVID vs. Transplant2 | COVID vs. Donor2 | Transplant vs. Donor2 | |
bacterial_infections_y_1_n_2 | 0.7 | 0.053 | 0.037 | |||
1 | 5 (31%) | 0 (0%) | 5 (42%) | |||
2 | 11 (69%) | 12 (100%) | 7 (58%) | |||
viral_infections_y_1_n_2 | 0.7 | 0.053 | 0.037 | |||
1 | 5 (31%) | 0 (0%) | 5 (42%) | |||
2 | 11 (69%) | 12 (100%) | 7 (58%) | |||
fungal_infections_y_1_n_2 | 0.053 | 0.053 | >0.9 | |||
1 | 5 (31%) | 0 (0%) | 0 (0%) | |||
2 | 11 (69%) | 12 (100%) | 12 (100%) | |||
inf_score | >0.9 | <0.001 | <0.001 | |||
0 | 5 (31%) | 12 (100%) | 3 (25%) | |||
1 | 8 (50%) | 0 (0%) | 8 (67%) | |||
2 | 2 (12%) | 0 (0%) | 1 (8.3%) | |||
3 | 1 (6.2%) | 0 (0%) | 0 (0%) | |||
1 n (%) | ||||||
2 Fisher's exact test |
• L’associaz con gli i ag infettivi era maggiormente presente in paz COVID con lunga data di malattia
Associazione di infezioni (si/no) con durata della malattia, i.e. gli infetti sono hanno ICU LOS o H LOS più lunghe?
• La maggiore neutrofilia nei COVID era correlata con le infezioni o era presente a prescindere ?
db_los <- db |> select(
icu_los,
h_los,
bacterial_infections_y_1_n_2,
viral_infections_y_1_n_2,
fungal_infections_y_1_n_2,
group_1_covid_2_transplant_3_donatore,
neutrophilic_granulocytes_percent
) |>
mutate(across(c(bacterial_infections_y_1_n_2:fungal_infections_y_1_n_2), ~ifelse(.==1, 'Yes', 'No')))
tbl_summary(db_los |> select(icu_los,
h_los,
bacterial_infections_y_1_n_2,
group_1_covid_2_transplant_3_donatore,
neutrophilic_granulocytes_percent) |>
filter(group_1_covid_2_transplant_3_donatore == '1'),
by = bacterial_infections_y_1_n_2,
missing = 'no',
type = c(neutrophilic_granulocytes_percent) ~ 'continuous'
) |>
add_p() |>
modify_caption('**Bacterial**')
## Warning for variable 'icu_los':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'h_los':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'neutrophilic_granulocytes_percent':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
Characteristic | No, N = 111 | Yes, N = 51 | p-value2 |
---|---|---|---|
icu_los | 24 (16, 40) | 15 (15, 18) | 0.4 |
h_los | 33 (30, 60) | 30 (18, 60) | 0.5 |
group_1_covid_2_transplant_3_donatore | >0.9 | ||
1 | 11 (100%) | 5 (100%) | |
2 | 0 (0%) | 0 (0%) | |
3 | 0 (0%) | 0 (0%) | |
neutrophilic_granulocytes_percent | 60 (45, 85) | 50 (40, 90) | >0.9 |
1 Median (IQR); n (%) | |||
2 Wilcoxon rank sum test; Fisher's exact test |
tbl_summary(db_los |> select(icu_los,
h_los,
viral_infections_y_1_n_2,
group_1_covid_2_transplant_3_donatore,
neutrophilic_granulocytes_percent) |>
filter(group_1_covid_2_transplant_3_donatore == '1'),
by = viral_infections_y_1_n_2,
missing = 'no',
type = c(neutrophilic_granulocytes_percent) ~ 'continuous') |>
add_p() |>
modify_caption('**Viral**')
## Warning for variable 'icu_los':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'h_los':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'neutrophilic_granulocytes_percent':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
Characteristic | No, N = 111 | Yes, N = 51 | p-value2 |
---|---|---|---|
icu_los | 23 (12, 30) | 18 (18, 24) | 0.7 |
h_los | 30 (28, 60) | 33 (30, 41) | 0.8 |
group_1_covid_2_transplant_3_donatore | >0.9 | ||
1 | 11 (100%) | 5 (100%) | |
2 | 0 (0%) | 0 (0%) | |
3 | 0 (0%) | 0 (0%) | |
neutrophilic_granulocytes_percent | 50 (40, 85) | 60 (50, 90) | 0.6 |
1 Median (IQR); n (%) | |||
2 Wilcoxon rank sum test; Fisher's exact test |
tbl_summary(db_los |> select(icu_los,
h_los,
fungal_infections_y_1_n_2,
group_1_covid_2_transplant_3_donatore,
neutrophilic_granulocytes_percent) |>
filter(group_1_covid_2_transplant_3_donatore == '1'),
by = fungal_infections_y_1_n_2,
missing = 'no',
type = c(neutrophilic_granulocytes_percent) ~ 'continuous') |>
add_p() |>
modify_caption('**Fungal**')
## Warning for variable 'icu_los':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'h_los':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'neutrophilic_granulocytes_percent':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
Characteristic | No, N = 111 | Yes, N = 51 | p-value2 |
---|---|---|---|
icu_los | 18 (12, 24) | 28 (26, 53) | 0.079 |
h_los | 33 (22, 50) | 30 (30, 79) | 0.5 |
group_1_covid_2_transplant_3_donatore | >0.9 | ||
1 | 11 (100%) | 5 (100%) | |
2 | 0 (0%) | 0 (0%) | |
3 | 0 (0%) | 0 (0%) | |
neutrophilic_granulocytes_percent | 50 (40, 85) | 60 (50, 90) | 0.3 |
1 Median (IQR); n (%) | |||
2 Wilcoxon rank sum test; Fisher's exact test |
C’è una tendenza per le infezioni fungine, non per il resto.
• Vi sono differenze di cellularità (macrofagi, neutrofili, linfociti, fibrina, sangue e pneumociti reattivi tra i due gruppi (COVID vs IC controls) ?
db_cel <- db |> select(group_1_covid_2_transplant_3_donatore,
macrophages_percent:hyperplastic_pneumocytes_y_1_n_2) |>
filter(group_1_covid_2_transplant_3_donatore == 1 | group_1_covid_2_transplant_3_donatore == 2) |>
mutate(group_1_covid_2_transplant_3_donatore = case_when(
group_1_covid_2_transplant_3_donatore == 1 ~ 'COVID',
TRUE ~ 'Transplant')) |>
droplevels() # altrimenti tieni anche i donatori anche se non ci sono più
tbl_summary(db_cel, by = group_1_covid_2_transplant_3_donatore,
type = c(lymphocytes_percent) ~ 'continuous') |>
add_p()
## Warning for variable 'macrophages_percent':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'lymphocytes_percent':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'neutrophilic_granulocytes_percent':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
Characteristic | COVID, N = 161 | Transplant, N = 121 | p-value2 |
---|---|---|---|
macrophages_percent | 40 (10, 52) | 90 (90, 95) | <0.001 |
lymphocytes_percent | 0.0 (0.0, 0.0) | 6.5 (5.0, 10.0) | <0.001 |
neutrophilic_granulocytes_percent | 55 (40, 90) | 0 (0, 2) | <0.001 |
fibrin_y_1_n_2 | <0.001 | ||
1 | 16 (100%) | 0 (0%) | |
2 | 0 (0%) | 12 (100%) | |
eritrocytes_y_1_n_2 | <0.001 | ||
1 | 15 (94%) | 3 (25%) | |
2 | 1 (6.2%) | 9 (75%) | |
hyperplastic_pneumocytes_y_1_n_2 | 0.001 | ||
1 | 14 (88%) | 3 (25%) | |
2 | 2 (12%) | 9 (75%) | |
1 Median (IQR); n (%) | |||
2 Wilcoxon rank sum test; Pearson's Chi-squared test; Fisher's exact test |
E’ tutto differente
tbl_summary(db |> select(group_1_covid_2_transplant_3_donatore,
ifna1_delta_ct:tnf_delta_ct
),
by = group_1_covid_2_transplant_3_donatore,
type = everything() ~ "continuous") |>
add_p()
Characteristic | 1, N = 161 | 2, N = 121 | 3, N = 121 | p-value2 |
---|---|---|---|---|
ifna1_delta_ct | 7 (6, 8) | 9 (7, 11) | 7 (6, 7) | 0.065 |
ifna16_delta_ct | 12 (10, 30) | 30 (26, 30) | 11 (11, 30) | 0.2 |
ifna17_delta_ct | 8.7 (7.9, 10.6) | 9.4 (8.4, 10.6) | 8.2 (7.4, 9.0) | 0.13 |
ifna2_delta_ct | 9 (8, 10) | 9 (9, 11) | 8 (8, 9) | 0.2 |
ifna6_delta_ct | 7.7 (7.0, 9.0) | 8.2 (7.4, 9.2) | 7.0 (6.6, 7.5) | 0.2 |
ifna7_delta_ct | 7.21 (6.86, 9.03) | 9.35 (8.14, 10.00) | 7.19 (6.89, 7.82) | 0.024 |
ifna8_delta_ct | 9 (8, 10) | 9 (8, 10) | 8 (7, 8) | 0.038 |
ifnb1_delta_ct | 8 (8, 10) | 8 (8, 10) | 8 (7, 9) | 0.3 |
ifng_delta_ct | 30 (30, 30) | 30 (-11, 30) | 30 (30, 30) | 0.041 |
il10_delta_ct | 30 (30, 30) | 30 (30, 30) | 30 (26, 30) | 0.2 |
il12a_delta_ct | 30 (30, 30) | 30 (30, 30) | 30 (30, 30) | 0.7 |
il12b_delta_ct | 30 (21, 30) | 30 (30, 30) | 30 (30, 30) | 0.4 |
il13_delta_ct | 30 (30, 30) | 30 (30, 30) | 30 (30, 30) | 0.094 |
il15_delta_ct | 30 (30, 30) | 30 (30, 30) | 30 (30, 30) | >0.9 |
il16_delta_ct | 30 (30, 30) | 22 (12, 30) | 30 (30, 30) | 0.3 |
il17a_delta_ct | 30 (30, 30) | 30 (30, 30) | 30 (30, 30) | 0.3 |
il18_delta_ct | 30 (30, 30) | 30 (26, 30) | 30 (30, 30) | 0.2 |
il1a_delta_ct | 30 (25, 30) | 30 (12, 30) | 30 (30, 30) | 0.068 |
il1b_delta_ct | 10 (8, 30) | 12 (11, 30) | 30 (30, 30) | 0.005 |
il2_delta_ct | 30 (30, 30) | 30 (30, 30) | 30 (30, 30) | 0.5 |
il3_delta_ct | 30.0000 (30.0000, 30.0000) | 30.0000 (30.0000, 30.0000) | 30.0000 (30.0000, 30.0000) | 0.5 |
il4_delta_ct | 30 (30, 30) | 30 (30, 30) | 30 (30, 30) | 0.2 |
il5_delta_ct | 30 (30, 30) | 30 (30, 30) | 30 (30, 30) | 0.7 |
il6_delta_ct | 30 (25, 30) | 30 (26, 30) | 30 (10, 30) | 0.6 |
il8_delta_ct | 21 (8, 30) | 12 (10, 30) | 30 (13, 30) | 0.3 |
il9_delta_ct | 12 (10, 30) | 30 (30, 30) | 30 (14, 30) | 0.014 |
lta_delta_ct | 30 (30, 30) | 30 (30, 30) | 30 (30, 30) | 0.3 |
tnf_delta_ct | 30 (16, 30) | 30 (11, 30) | 30 (30, 30) | 0.2 |
1 Median (IQR) | ||||
2 Kruskal-Wallis rank sum test |
IFNA1 e IL1A non sono più significative (lo erano senza gli ultimi 4 aggiunti). Metto lo stesso i grafici
# graphs of significants --------------------------------------------------
out <- c('ifna1_delta_ct', 'ifna7_delta_ct', 'ifna8_delta_ct', 'ifng_delta_ct', 'il1a_delta_ct', 'il1b_delta_ct', 'il9_delta_ct')
graphs<- function(out){
ggbetweenstats(
data = db,
x = group_1_covid_2_transplant_3_donatore,
y = {{out}},
type = 'np',
title = paste0(out)
)
}
map(out, graphs)
## [[1]]
##
## [[2]]
##
## [[3]]
##
## [[4]]
##
## [[5]]
##
## [[6]]
##
## [[7]]
L’associazione più interessante sembre sia con IL9, che è completamente diversa nei COVID e quindi sembra “tipica” della malattia
• (solo COVID) Le citochine alterate erano maggiormente o meno alterate nei pazienti COVID con agenti infettivi ( eventualmente differenziando per agente microbico)
db_cito <- db |> select(
bacterial_infections_y_1_n_2,
viral_infections_y_1_n_2,
fungal_infections_y_1_n_2,
group_1_covid_2_transplant_3_donatore,
ifna1_delta_ct,
ifna7_delta_ct,
ifna8_delta_ct,
ifng_delta_ct,
il1a_delta_ct,
il1b_delta_ct,
il9_delta_ct,
bmi,
age_years
) |>
mutate(across(c(bacterial_infections_y_1_n_2:fungal_infections_y_1_n_2), ~ifelse(.==1, 'Yes', 'No')))
tbl_summary(db_cito |> select(-viral_infections_y_1_n_2, -fungal_infections_y_1_n_2) |>
filter(group_1_covid_2_transplant_3_donatore == '1'),
by = bacterial_infections_y_1_n_2,
missing = 'no',
type = c(ifng_delta_ct, il1a_delta_ct) ~ 'continuous'
) |>
add_p() |>
modify_caption('**Bacterial**')
## Warning for variable 'ifna1_delta_ct':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'ifna7_delta_ct':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'ifna8_delta_ct':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'ifng_delta_ct':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'il1a_delta_ct':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'il1b_delta_ct':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'il9_delta_ct':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'age_years':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
Characteristic | No, N = 111 | Yes, N = 51 | p-value2 |
---|---|---|---|
group_1_covid_2_transplant_3_donatore | >0.9 | ||
1 | 11 (100%) | 5 (100%) | |
2 | 0 (0%) | 0 (0%) | |
3 | 0 (0%) | 0 (0%) | |
ifna1_delta_ct | 7 (6, 8) | 7 (5, 7) | 0.6 |
ifna7_delta_ct | 7 (7, 9) | 7 (7, 7) | 0.5 |
ifna8_delta_ct | 9 (8, 10) | 8 (8, 8) | 0.11 |
ifng_delta_ct | 30.0 (30.0, 30.0) | 30.0 (30.0, 30.0) | 0.2 |
il1a_delta_ct | 30 (30, 30) | 30 (8, 30) | 0.3 |
il1b_delta_ct | 10 (9, 30) | 7 (6, 30) | 0.5 |
il9_delta_ct | 11 (9, 23) | 14 (13, 30) | 0.2 |
bmi | 29 (26, 36) | 38 (32, 40) | 0.4 |
age_years | 61 (57, 70) | 50 (46, 73) | 0.4 |
1 n (%); Median (IQR) | |||
2 Fisher's exact test; Wilcoxon rank sum test; Wilcoxon rank sum exact test |
tbl_summary(db_cito |> select(-bacterial_infections_y_1_n_2, -fungal_infections_y_1_n_2) |>
filter(group_1_covid_2_transplant_3_donatore == '1'),
by = viral_infections_y_1_n_2,
missing = 'no',
type = c(ifng_delta_ct, il1a_delta_ct) ~ 'continuous'
) |>
add_p() |>
modify_caption('**Viral**')
## Warning for variable 'ifna1_delta_ct':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'ifna7_delta_ct':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'ifna8_delta_ct':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'ifng_delta_ct':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'il1a_delta_ct':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'il1b_delta_ct':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'il9_delta_ct':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'age_years':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
Characteristic | No, N = 111 | Yes, N = 51 | p-value2 |
---|---|---|---|
group_1_covid_2_transplant_3_donatore | >0.9 | ||
1 | 11 (100%) | 5 (100%) | |
2 | 0 (0%) | 0 (0%) | |
3 | 0 (0%) | 0 (0%) | |
ifna1_delta_ct | 7 (6, 19) | 7 (6, 7) | 0.5 |
ifna7_delta_ct | 7 (7, 9) | 7 (7, 7) | >0.9 |
ifna8_delta_ct | 9 (8, 20) | 8 (8, 8) | 0.4 |
ifng_delta_ct | 30.0 (30.0, 30.0) | 30.0 (30.0, 30.0) | 0.6 |
il1a_delta_ct | 30 (9, 30) | 30 (30, 30) | 0.2 |
il1b_delta_ct | 9 (7, 22) | 30 (10, 30) | 0.15 |
il9_delta_ct | 15 (10, 30) | 11 (11, 13) | 0.6 |
bmi | 30 (28, 35) | 40 (25, 50) | 0.7 |
age_years | 60 (51, 73) | 61 (60, 64) | >0.9 |
1 n (%); Median (IQR) | |||
2 Fisher's exact test; Wilcoxon rank sum test; Wilcoxon rank sum exact test |
tbl_summary(db_cito |> select(-viral_infections_y_1_n_2, -bacterial_infections_y_1_n_2) |>
filter(group_1_covid_2_transplant_3_donatore == '1'),
by = fungal_infections_y_1_n_2,
missing = 'no',
type = c(ifng_delta_ct, il1a_delta_ct) ~ 'continuous'
) |>
add_p() |>
modify_caption('**Fungal**')
## Warning for variable 'ifna1_delta_ct':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'ifna7_delta_ct':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'ifna8_delta_ct':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'ifng_delta_ct':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'il1a_delta_ct':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'il1b_delta_ct':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'il9_delta_ct':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
## Warning for variable 'age_years':
## simpleWarning in wilcox.test.default(x = DATA[[1L]], y = DATA[[2L]], ...): cannot compute exact p-value with ties
Characteristic | No, N = 111 | Yes, N = 51 | p-value2 |
---|---|---|---|
group_1_covid_2_transplant_3_donatore | >0.9 | ||
1 | 11 (100%) | 5 (100%) | |
2 | 0 (0%) | 0 (0%) | |
3 | 0 (0%) | 0 (0%) | |
ifna1_delta_ct | 7 (6, 19) | 6 (5, 7) | 0.2 |
ifna7_delta_ct | 7 (7, 9) | 7 (7, 8) | 0.8 |
ifna8_delta_ct | 8 (8, 20) | 9 (8, 9) | 0.6 |
ifng_delta_ct | 30.0 (30.0, 30.0) | 30.0 (30.0, 30.0) | 0.6 |
il1a_delta_ct | 30 (20, 30) | 30 (30, 30) | 0.9 |
il1b_delta_ct | 10 (7, 30) | 15 (10, 30) | 0.5 |
il9_delta_ct | 13 (10, 30) | 11 (8, 14) | 0.3 |
bmi | 30 (27, 39) | 31 (27, 50) | 0.5 |
age_years | 64 (53, 73) | 60 (45, 60) | 0.14 |
1 n (%); Median (IQR) | |||
2 Fisher's exact test; Wilcoxon rank sum test; Wilcoxon rank sum exact test |
No, nessuna differenza di espressione delle citochine in infetti e non (gruppo COVID)
• Relativamente ai pazienti COVID: Quale fattore era maggiormente predittivo di cattiva outcome: partern citochinico; coinfezioni ? caratteristiche del paz , pattern di citologiase puo applicare qualche algoritmo di machine learning sarebbe carino )
Gli outcome sono: Mortalità Long stay ICU Utilizzo di ECMO Ospedalizzazione
db_boruta <- db |> filter(group_1_covid_2_transplant_3_donatore ==1) |>
droplevels() |>
select(sex_1_m_2_f,
age_years,
bmi,
comorbidities_1_y_1_n_0:tnf_delta_ct,
status_vivo_1_morto_0,
icu_los,
h_los,
ecmo_y_1_n_2)
# Boruta non vuole missing, li imputo sempre con RF
db_imp <- randomForestSRC::impute(data = as.data.frame(db_boruta))
# seed <- c(1, 23, 3011, 12345, 654321) #ne laascio solo uno perché sono consistenti
seed <- c(1, 23, 3011, 12345, 654321)
# creo una funzione per far girare boruta in automatico con tutti i seed
boruta_fun <- function(seed){
set.seed(seed)
boruta.lungs_train <- Boruta(status_vivo_1_morto_0 ~ . ,
maxRuns = 1000, # aumento il numero per includere le variabili escluse
data = db_imp |> select(-icu_los, -h_los, -ecmo_y_1_n_2))
print(boruta.lungs_train)
boruta.lungs <- TentativeRoughFix(boruta.lungs_train)
print(boruta.lungs)
plot <- plot(boruta.lungs, xlab = "", las = 3, cex.axis = 0.8,
whichShadow = c(FALSE, FALSE, FALSE),
pars = par(mar = c(9.5,4,2,1)))
lungs_df <- attStats(boruta.lungs) %>%
relocate(decision) %>%
dplyr::select(-normHits) %>% # così ci sta nella pagina
arrange(decision, desc(meanImp))
return(list(lungs_df, plot))
}
boruta_res <- map(seed, ~ boruta_fun(.x))
## Boruta performed 999 iterations in 30.05836 secs.
## 1 attributes confirmed important: age_years;
## 41 attributes confirmed unimportant: bacterial_infections_y_1_n_2,
## bmi, comorbidities_1_y_1_n_0, eritrocytes_y_1_n_2, fibrin_y_1_n_2 and
## 36 more;
## 1 tentative attributes left: tnf_delta_ct;
## Boruta performed 999 iterations in 30.05836 secs.
## Tentatives roughfixed over the last 999 iterations.
## 1 attributes confirmed important: age_years;
## 42 attributes confirmed unimportant: bacterial_infections_y_1_n_2,
## bmi, comorbidities_1_y_1_n_0, eritrocytes_y_1_n_2, fibrin_y_1_n_2 and
## 37 more;
## Boruta performed 999 iterations in 20.48649 secs.
## 1 attributes confirmed important: age_years;
## 41 attributes confirmed unimportant: bacterial_infections_y_1_n_2,
## bmi, comorbidities_1_y_1_n_0, eritrocytes_y_1_n_2, fibrin_y_1_n_2 and
## 36 more;
## 1 tentative attributes left: tnf_delta_ct;
## Boruta performed 999 iterations in 20.48649 secs.
## Tentatives roughfixed over the last 999 iterations.
## 1 attributes confirmed important: age_years;
## 42 attributes confirmed unimportant: bacterial_infections_y_1_n_2,
## bmi, comorbidities_1_y_1_n_0, eritrocytes_y_1_n_2, fibrin_y_1_n_2 and
## 37 more;
## Boruta performed 112 iterations in 2.664259 secs.
## 1 attributes confirmed important: age_years;
## 42 attributes confirmed unimportant: bacterial_infections_y_1_n_2,
## bmi, comorbidities_1_y_1_n_0, eritrocytes_y_1_n_2, fibrin_y_1_n_2 and
## 37 more;
## Warning in TentativeRoughFix(boruta.lungs_train): There are no Tentative
## attributes! Returning original object.