diff --git a/flu_stats_unpaired_sam.R b/flu_stats_unpaired_sam.R index 1ed0664..570c575 100755 --- a/flu_stats_unpaired_sam.R +++ b/flu_stats_unpaired_sam.R @@ -35,6 +35,13 @@ lf = sam_adults_lf[sam_adults_lf$flustat == 1,] table(lf$timepoint) length(unique(lf$mosaic)) lf$timepoint = paste0("t", lf$timepoint) + +if (table(lf$flustat) == table(sam_adults_lf$flustat)[[2]]){ + cat("Analysing Flu positive patients for:", my_sample_type) +}else{ + cat("FAIL: problem with subsetting data for:", my_sample_type) + quit() +} ######################################################################## # Unpaired stats at each timepoint b/w groups: wilcoxon UNpaired analysis # with correction diff --git a/flu_stats_unpaired_serum.R b/flu_stats_unpaired_serum.R index 29e2f6a..0400963 100755 --- a/flu_stats_unpaired_serum.R +++ b/flu_stats_unpaired_serum.R @@ -35,6 +35,13 @@ lf = serum_adults_lf[serum_adults_lf$flustat == 1,] table(lf$timepoint) lf$timepoint = paste0("t", lf$timepoint) +if (table(lf$flustat) == table(serum_adults_lf$flustat)[[2]]){ + cat("Analysing Flu positive patients for:", my_sample_type) +}else{ + cat("FAIL: problem with subsetting data for:", my_sample_type) + quit() +} + ######################################################################## # Unpaired stats at each timepoint b/w groups: wilcoxon UNpaired analysis with correction #######################################################################