
Merge Logistic Regression and Solo PPV Statistics
Source:R/plot_estimates.R
merge_logreg_soloppv.RdThis function merges logistic regression model statistics with solo PPV statistics and creates a combined plot.
Value
A list containing:
combined: A merged data frame of logistic regression and PPV statistics.plot: A ggplot object showing the relationship between model estimates and PPV.
Examples
if (FALSE) { # \dontrun{
soloPPV_cipro <- solo_ppv(ecoli_geno, ecoli_pheno,
pheno_drug = "Ciprofloxacin",
geno_class = c("Quinolones"),
sir_col = "pheno"
)
logistic_cipro <- amr_logistic(ecoli_geno, ecoli_pheno,
"Ciprofloxacin", c("Quinolones"),
maf = 5
)
allstatsR <- merge_logreg_soloppv(logistic_cipro$modelR,
soloPPV_cipro$solo_stats %>% filter(category == "R"),
title = "Quinolone markers vs Cip R"
)
} # }