ttest_scores function

ttest_scores

ttest_scores

#' Function that creates a boxplot with a continuous variable split using the binary variable

ttest_scores(dat, pred, pheno)

Arguments

  • dat: The data.frame containing the 2 variables
  • pred: character indicating the y variable
  • pheno: character indicating the binary variable

Returns

plotly boxplot with the continuous variable split using the binary variable

Examples

library(MiMIR) library(plotly) #load the dataset metabolic_measures <- synthetic_metabolic_dataset phenotypes <- synthetic_phenotypic_dataset #Compute the mortality score mortScore<-comp.mort_score(metabolic_measures,quiet=TRUE) dat<-data.frame(predictor=mortScore, pheno=phenotypes$sex) colnames(dat)<-c("predictor","pheno") ttest_scores(dat = dat, pred= "mortScore", pheno="sex")
  • Maintainer: Daniele Bizzarri
  • License: GPL-3
  • Last published: 2024-02-01

Useful links