Last updated: 2022-03-14

Checks: 5 1

Knit directory: yeln_2019_spermtyping/

This reproducible R Markdown analysis was created with workflowr (version 1.7.0). The Checks tab describes the reproducibility checks that were applied when the results were created. The Past versions tab lists the development history.


Great job! The global environment was empty. Objects defined in the global environment can affect the analysis in your R Markdown file in unknown ways. For reproduciblity it’s best to always run the code in an empty environment.

The command set.seed(20190102) was run prior to running the code in the R Markdown file. Setting a seed ensures that any results that rely on randomness, e.g. subsampling or permutations, are reproducible.

Great job! Recording the operating system, R version, and package versions is critical for reproducibility.

Nice! There were no cached chunks for this analysis, so you can be confident that you successfully produced the results during this run.

Great job! Using relative paths to the files within your workflowr project makes it easier to run your code on other machines.

Tracking code development and connecting the code version to the results is critical for reproducibility. To start using Git, open the Terminal and type git init in your project directory.


This project is not being versioned with Git. To obtain the full reproducibility benefits of using workflowr, please see ?wflow_start.


scCNV versus BC1F1 bulk sequencing samples

savePNG <- function(plot_p, saveToFile, dpi=300, fig.width = 14,
                    fig.height =10,
                    bothPngPDF= FALSE){
    png(saveToFile, width = fig.width,
          height = fig.height, units = "in",
          pointsize = 12, res = dpi)
      print(plot_p)
      dev.off()
}
scCNV <- readRDS(file  = "~/Projects/rejy_2020_single-sperm-co-calling/output/outputR/analysisRDS/countsAll-settings4.3-scCNV-CO-counts_07-mar-2022.rds")

scCNV by Fancm genotype

x <- c("mutant","mutant","wildtype","mutant",
                                           "wildtype","wildtype")
xx <- c("Fancm-/-","Fancm-/-","Fancm+/+","Fancm-/-",
                                           "Fancm+/+","Fancm+/+")

scCNV$sampleType <- plyr::mapvalues(scCNV$sampleGroup,from = c("WC_522",
                                                               "WC_526",
                                                               "WC_CNV_42",
                                                               "WC_CNV_43",
                                                               "WC_CNV_44",
                                                               "WC_CNV_53"),
                                    to =xx)

scCNV_dist_type <- calGeneticDist(scCNV,group_by = "sampleType")

colSums(as.matrix(rowData(scCNV_dist_type)$kosambi))
Fancm-/- Fancm+/+ 
1387.336 1227.412 

Bulk bc1f1

bc1f1_samples <- readRDS(file = "output/outputR/analysisRDS/all_rse_count_07-20.rds")
bc1f1_samples_dist <- calGeneticDist(bc1f1_samples,group_by = "sampleGroup"  )
bc1f1_samples_dist_male <- calGeneticDist(bc1f1_samples[,bc1f1_samples$sampleGroup %in%  
                                                          c("Male_HET","Male_WT","Male_KO")],
                                          group_by = "sampleGroup"  )

bc1f1_samples_dist_female <- calGeneticDist(bc1f1_samples[,bc1f1_samples$sampleGroup %in%  
                                                          c("Female_HET","Female_WT","Female_KO")],group_by = "sampleGroup")
scCNV_dist_bin_dist <- calGeneticDist(scCNV,group_by = "sampleType",bin_size = 1e7)

bc1f1_samples_dist_male_bin_dist <- calGeneticDist(bc1f1_samples[,bc1f1_samples$sampleGroup %in%
                                                                   c("Male_HET","Male_WT","Male_KO")],
                                                   bin_size = 1e7,
                                                   group_by = "sampleGroup")

bc1f1_samples_dist_bin_dist <- calGeneticDist(bc1f1_samples,
                                                   bin_size = 1e7,
                                                   group_by = "sampleGroup")

combined_bin_dist <- scCNV_dist_bin_dist
mcols(combined_bin_dist ) <- cbind(mcols(scCNV_dist_bin_dist),
                                   apply(mcols(bc1f1_samples_dist_male_bin_dist),
                                         2,function(x) (-1)*x))
plotGeneticDist(combined_bin_dist,cumulative = F,chr = "chr8")+
  scale_color_manual("sampleType",
                     labels = c("mutant"= "single sperm KO", "wildtype"="single sperm WT",
                                "Male_KO" = "male KO" ,  "Male_WT" = "male WT" ),
                     values = c("mutant" = "#2b2d42",
                                "wildtype" = "#d90429",
                                  "Male_KO" = "#8d99ae",
                                "Male_WT" = "#e75466",
                                "Male_HET" = "#76797a"))
Scale for 'colour' is already present. Adding another scale for 'colour',
which will replace the existing scale.

    # values = c("mutant" = "#2b2d42",
    #                             "wildtype" = "#d90429",
    #                               "Male_KO" = "#8d99ae",
    #                             "Male_WT" = "#e75466",
    #                             "Male_HET" = "#76797a")

chr_cums <- list()
for(chr in paste0("chr",c(1:19)) ){
  
  suppressMessages(
     chr_cums[[chr]] <-
plotGeneticDist(combined_bin_dist,cumulative = F,chr =chr)+
  scale_color_manual("sampleType",
                     labels = c("Fancm-/-"= "single sperm KO", 
                                "Fancm+/+"="single sperm WT",
                                "Male_KO" = "male KO" ,  
                                "Male_WT" = "male WT" ),
                     values = c("Fancm-/-" = "cornflowerblue",
                                "Fancm+/+" = "tan1",
                                  "Male_KO" = "cornflowerblue",
                                "Male_WT" = "tan1",
                                "Male_HET" = "grey50"))+geom_hline(yintercept = 0,
                                                     linetype = "dashed",alpha=0.4)+
  scale_y_continuous(breaks = c(-15,-10,-5,0,5,10,15,20),
                     labels = c("15","10","5","0","5","10","15","20"))+
  scale_x_continuous(labels = scales::unit_format(unit = "M", 
                                                  scale = 1e-06),limits = c(0,196e6),
                     breaks= c(0,50e6,100e6,150e6,195e6))+
  guides(color="none")+xlab("")+ylab("")+
  theme(panel.grid.minor = element_line(colour = "grey", size = 0.2),
        panel.grid.major = element_blank(),
        plot.margin = margin(t=10,r=15),
        strip.text.x = element_text(size =22)))
}

scCNV versus BC1F1 bulk sequencing samples across all chromosomes

mChrThresPlotsscCNV_bc1f1male <- marrangeGrob(chr_cums, nrow=7, ncol=3,
                               layout_matrix = matrix(c(1:19,NA,NA),
                                                      nrow=7,byrow = T),
                               top = textGrob(" "),
                               bottom = textGrob("Chromosome positions",gp = gpar(fontsize = 25)),                                        left = textGrob("CentiMorgans per 10 megabase",
                                                                                                                                                          gp = gpar(fontsize = 25),
                                                                                                                                                          rot = 90))
mChrThresPlotsscCNV_bc1f1male

savePNG

scCNV versus BC1F1 bulk sequencing samples 4 chromosomes

Up: scCNV

Down: BC1F1 bulk sequencing

plotGeneticDistCustmise <- function (gr, bin = TRUE, chr = NULL, cumulative = FALSE,
                                     line_size = 2) 
{
  col_to_plot <- colnames(GenomicRanges::mcols(gr))
  sample_group_colors <- RColorBrewer::brewer.pal(ifelse(length(col_to_plot) > 
    2, length(col_to_plot), 3), name = "Set1")
  names(sample_group_colors)[seq_along(col_to_plot)] <- col_to_plot
  if (cumulative) {
    GenomicRanges::mcols(gr) <- apply(mcols(gr), 2, function(x, 
      seq = as.character(seqnames(gr))) {
      temp_df <- data.frame(x = x, seq = seq) %>% dplyr::group_by(seq) %>% 
        dplyr::mutate(cum = cumsum(x))
      temp_df$cum
    })
  }
  plot_df <- data.frame(gr)
  colnames(plot_df)[(ncol(plot_df) - length(col_to_plot) + 
    1):ncol(plot_df)] <- col_to_plot
  plot_df <- plot_df %>% dplyr::mutate(x_tick = 0.5 * (.data$start + 
    .data$end))
  plot_df <- plot_df %>% tidyr::pivot_longer(cols = col_to_plot, 
    names_to = "SampleGroup", values_to = "bin_dist")
  x_tick <- bin_dist <- end <- SampleGroup <- NULL
  if (is.null(chr)) {
    p <- plot_df %>% ggplot() + geom_step(mapping = aes(x = x_tick, 
      y = bin_dist, color = SampleGroup), size = line_size)
  }
  else {
    p <- plot_df %>% dplyr::filter(seqnames %in% chr) %>% 
      ggplot() + geom_step(mapping = aes(x = end, y = bin_dist, 
      color = SampleGroup), size = line_size)
  }
  p <- p + scale_x_continuous(labels = scales::unit_format(unit = "M", 
    scale = 1e-06)) + facet_wrap(. ~ seqnames, ncol = 1, 
    scales = "free") + theme_classic(base_size = 18) + xlab("Chromosome positions") + 
    scale_color_manual(values = sample_group_colors)
  if (cumulative) {
    p + ylab("cumulative centiMorgans")
  }
  else {
    p + ylab("centiMorgans")
  }
}

Previously selected chromosomes 8, 9, 11, 18

chr_cums <- list()
for(chr in paste0("chr",c(8,9,11,18))){
  
  suppressMessages(
     chr_cums[[chr]] <-
plotGeneticDistCustmise(combined_bin_dist,cumulative = F,chr =chr, line_size = 2)+
  scale_color_manual("sampleType",
                     labels = c("Fancm-/-"= "single sperm KO", 
                                "Fancm+/+"="single sperm WT",
                                "Male_KO" = "male KO" ,  
                                "Male_WT" = "male WT" ),
                     values = c("Fancm-/-" = "cornflowerblue",
                                "Fancm+/+" = "tan1",
                                  "Male_KO" = "cornflowerblue",
                                "Male_WT" = "tan1",
                                "Male_HET" = "grey50"))+geom_hline(yintercept = 0,
                                                     linetype = "dashed",alpha=0.4)+
  scale_y_continuous(breaks = c(-15,-10,-5,0,5,10,15,20),
                     labels = c("15","10","5","0","5","10","15","20"))+
  scale_x_continuous(labels = scales::unit_format(unit = "M", 
                                                  scale = 1e-06),
                     limits = c(0,196e6),
                     breaks= c(0,50e6,100e6,150e6,195e6))+
  guides(color="none")+xlab("")+ylab("")+
  theme(panel.grid.minor = element_line(colour = "grey", size = 0.2),
        panel.grid.major = element_blank(),
        strip.text.x = element_text(size = 22),
        axis.text.y = element_text(size = 25),
         axis.text.x = element_text(size = 23),
        axis.title = element_text(size = 25)))
}
# arg_mchrs <- arrangeGrob(chr_cums$chr8+theme(strip.text = element_text(size = 20),
#                                              axis.text = element_text(size = 20),
#                                              axis.title.x = element_blank(),
#                                              plot.margin = margin(t=10,r=15)),
#                          chr_cums$chr9+theme(strip.text = element_text(size = 22),
#                                              axis.text = element_text(size = 20),
#                                              axis.title.x = element_blank(),
#                                              plot.margin = margin(t=10,r=15)),
#                          chr_cums$chr11+theme(strip.text = element_text(size = 22),
#                                               axis.text = element_text(size = 20),
#                                               plot.margin = margin(t=10,r=15)),
#                          chr_cums$chr18+theme(strip.text = element_text(size = 22),
#                                               axis.text = element_text(size = 25),plot.margin = margin(t=10,r=15)))
# 


arg_mchrs <- arrangeGrob(chr_cums$chr8+theme(axis.title.x = element_blank(),
                                             plot.margin = margin(t=10,r=8)),
                         chr_cums$chr9+theme(axis.title.x = element_blank(),
                                             plot.margin = margin(t=10,r=8)),
                         chr_cums$chr11+theme(plot.margin = margin(t=10,r=8)),
                         chr_cums$chr18+theme(plot.margin = margin(t=10,r=8)))
# grid.arrange(arg_mchrs1,left =  textGrob("Cumulative centiMorgans",rot = 90,gp = gpar(fontsize=25)),
#              bottom =  textGrob("Chromosome positions",rot = 0,gp = gpar(fontsize=25)),nrow=1)
# 
# grid.arrange(arg_mchrs2,left =  textGrob("Cumulative centiMorgans",rot = 90,gp = gpar(fontsize=25)),
#              bottom =  textGrob("Chromosome positions",rot = 0,gp = gpar(fontsize=25)),nrow =1,ncol=1)


grid.arrange(arg_mchrs,left =  textGrob("CentiMorgans per 10 megabase",rot = 90,
                                        gp = gpar(fontsize=25)),
             bottom =  textGrob("Chromosome positions",rot = 0,
                                gp = gpar(fontsize=25)))

The current selected chromosomes

chr_cums <- list()
for(chr in paste0("chr",c(1,4,8,11))){
  
  suppressMessages(
     chr_cums[[chr]] <-
plotGeneticDistCustmise(combined_bin_dist,cumulative = F,chr =chr, line_size = 2)+
  scale_color_manual("sampleType",
                     labels = c("Fancm-/-"= "single sperm KO", 
                                "Fancm+/+"="single sperm WT",
                                "Male_KO" = "male KO" ,  
                                "Male_WT" = "male WT" ),
                     values = c("Fancm-/-" = "cornflowerblue",
                                "Fancm+/+" = "tan1",
                                  "Male_KO" = "cornflowerblue",
                                "Male_WT" = "tan1",
                                "Male_HET" = "grey50"))+geom_hline(yintercept = 0,
                                                     linetype = "dashed",alpha=0.4)+
  scale_y_continuous(breaks = c(-15,-10,-5,0,5,10,15,20),
                     labels = c("15","10","5","0","5","10","15","20"))+
  scale_x_continuous(labels = scales::unit_format(unit = "M", 
                                                  scale = 1e-06),limits = c(0,196e6),
                     breaks= c(0,50e6,100e6,150e6,195e6))+
  guides(color="none")+xlab("")+ylab("")+
  theme(panel.grid.minor = element_line(colour = "grey", size = 0.2),
        panel.grid.major = element_blank(),
        strip.text.x = element_text(size = 22),
        axis.text.y = element_text(size = 25),
         axis.text.x = element_text(size = 23),
        axis.title = element_text(size = 25)))
}
arg_mchrs <- arrangeGrob(chr_cums$chr1+theme(axis.title.x = element_blank(),
                                             plot.margin = margin(t=10,r=15)),
                         chr_cums$chr4+theme(axis.title.x = element_blank(),
                                             plot.margin = margin(t=10,r=15)),
                         chr_cums$chr8+theme(plot.margin = margin(t=10,r=15)),
                         chr_cums$chr11+theme(plot.margin = margin(t=10,r=15)))


grid.arrange(arg_mchrs,left =  textGrob("CentiMorgans per 10 megabase",rot = 90,
                                        gp = gpar(fontsize=25)),
             bottom =  textGrob("Chromosome positions",rot = 0,
                                gp = gpar(fontsize=25)))

BC1F1 female versus male

Down: female

Up: male

i = 1
mcols(bc1f1_samples_dist_bin_dist)[,c(2:4)] <- apply(mcols(bc1f1_samples_dist_bin_dist)[,c(2:4)],2,function(x){
 (-1)*x

})

plotGeneticDist(bc1f1_samples_dist_bin_dist,cumulative = F,chr = "chr8")+
  scale_color_manual("sampleType",
                     values = c("Female_WT" = "tan1",
                       "Female_KO" = "cornflowerblue",
                                "Female_HET" = "grey50",
                                  "Male_KO" = "cornflowerblue",
                                "Male_WT" = "tan1",
                                "Male_HET" = "grey50"))+
  scale_y_continuous(breaks = c(-15,-10,-5,0,5,10,15,20),
                     labels = c("15","10","5","0","5","10","15","20"))+
  scale_x_continuous(labels = scales::unit_format(unit = "M", 
                                                                scale = 1e-06),limits = c(0,196e6),
                                                                breaks= c(0,50e6,100e6,150e6,195e6))+
  guides(color="none")+xlab("")+ylab("")+theme(panel.grid.minor = 
                            element_line(colour = "grey", size = 0.2),
                          panel.grid.major = element_blank())
Scale for 'colour' is already present. Adding another scale for 'colour',
which will replace the existing scale.
Scale for 'x' is already present. Adding another scale for 'x', which will
replace the existing scale.

chr_cums <- list()
for(chr in paste0("chr",c(1:19)) ){
  
  suppressMessages(
     chr_cums[[chr]] <-
plotGeneticDist(bc1f1_samples_dist_bin_dist,cumulative = F,chr = chr)+
  scale_color_manual("sampleType",
                     values = c("Female_WT" = "tan1",
                       "Female_KO" = "cornflowerblue",
                                "Female_HET" = "grey50",
                                  "Male_KO" = "cornflowerblue",
                                "Male_WT" = "tan1",
                                "Male_HET" = "grey50"))+geom_hline(yintercept = 0,
                                                     linetype = "dashed",alpha=0.4)+
  scale_y_continuous(breaks = c(-15,-10,-5,0,5,10,15,20),
                     labels = c("15","10","5","0","5","10","15","20"))+
  scale_x_continuous(labels = scales::unit_format(unit = "M", 
                                                  scale = 1e-06),limits = c(0,196e6),
                     breaks= c(0,50e6,100e6,150e6,195e6))+
  guides(color="none")+xlab("")+ylab("")+theme(panel.grid.minor = 
                            element_line(colour = "grey", size = 0.2),axis.text.x = element_text(size=rel(0.8)),
                          panel.grid.major = element_blank(),
                           plot.margin = margin(t=10,r=15)))
}

mChrThresPlots_female_male <- marrangeGrob(chr_cums, ncol=3,
                               layout_matrix = matrix(c(1:19,NA,NA),nrow=7,byrow = T),
                               top = textGrob(" "),
                               bottom = textGrob("Chromosome positions",gp = gpar(fontsize = 25)),                                        left = textGrob("CentiMorgans per 10 megabase",
                                                                                                                                                          gp = gpar(fontsize = 25),
                                                                                                                                                          rot = 90))
mChrThresPlots_female_male

savePNG

Permutation for testing differences in genetic distances in each chromsome bin

Permutation is performed by permuting the sample type labels among the single cells or bulk samples and caculate the differences in genetic distances between sample groups.

register(BPPARAM = MulticoreParam(workers = 10))

permuteSampleType <- function(co_count, B = 1000, bin_size = 1e7,
                              permuteCol = "sampleType"){
  len_1 <- table(colData(co_count)[,permuteCol])[1]
  bbl <-   bplapply(1:B, function(x){
     
    permutedCoCount <- co_count
    type1Idx <- sample(seq(ncol(permutedCoCount)),len_1)
    type2Idx <- setdiff(seq(ncol(permutedCoCount)),type1Idx )
    permutedCoCount$sampleType[type1Idx] <- names(table(permutedCoCount$sampleType))[1]
    permutedCoCount$sampleType[type2Idx] <- names(table(permutedCoCount$sampleType))[2]
    
    permutedCoCount_dist_bin_dist <- calGeneticDist(permutedCoCount,group_by = permuteCol,
                                                    bin_size = bin_size)
    mcols(permutedCoCount_dist_bin_dist)
    
  })
 
  observed_dist_bin_dist <-  calGeneticDist(co_count,group_by = permuteCol,
                                                    bin_size = bin_size)
  observed_dist_bin_diff <- mcols(observed_dist_bin_dist)[,1] - mcols(observed_dist_bin_dist)[,2]

  mt_scnv_permute <- sapply(bbl,function(x){x[,2]})
  wt_scnv_permute <- sapply(bbl,function(x){x[,1]})
  permute_statistic <- mt_scnv_permute - wt_scnv_permute
  permute_statistic <- rowSums(permute_statistic >= observed_dist_bin_diff)
  permute_pvals <- permp(permute_statistic,nperm = B,n1 =len_1,n2 = ncol(co_count)-len_1)
  
  temp_gr <- observed_dist_bin_dist
  mcols(temp_gr) <- permute_pvals
  
  temp_gr
}
scCNV_pval_bins <- permuteSampleType(co_count = scCNV)
hist(scCNV_pval_bins$X)

After multiple testing correction:

scCNV_pval_bins_adj <- p.adjust(mcols(scCNV_pval_bins)[,1],"fdr")

mcols(scCNV_pval_bins) <- data.frame(scCNV_p.adj = scCNV_pval_bins_adj)

There is no bins that was detected as having significant differences in genetic distances in single sperm dataset.

any(scCNV_pval_bins$scCNV_p.adj<0.05)
[1] FALSE
bc1f1_samples_dist_male_2groups <- bc1f1_samples_dist_male
bc1f1_samples_dist_female_2groups <- bc1f1_samples_dist_female

bc1f1_samples_dist_male_2groups$sampleType <- plyr::mapvalues(bc1f1_samples_dist_male_2groups$sampleGroup,
                                                              from = c("Male_HET","Male_WT","Male_KO"),
                                                              to = c("Fancm+/*","Fancm+/*","Fancm-/-") )

bc1f1_samples_dist_female_2groups$sampleType <- plyr::mapvalues(bc1f1_samples_dist_female_2groups$sampleGroup,
                                                              from = c("Female_HET","Female_WT","Female_KO"),
                                                              to = c("Fancm+/*","Fancm+/*","Fancm-/-") )
bc1f1_samples_dist_female_2groups_pval_bins <- permuteSampleType(co_count = bc1f1_samples_dist_female_2groups)
bc1f1_male_samples_2groups_pval_bins <- permuteSampleType(co_count = bc1f1_samples_dist_male_2groups)


hist(bc1f1_male_samples_2groups_pval_bins$X)

hist(bc1f1_samples_dist_female_2groups_pval_bins$X)

bc1f1_male_samples_2groups_pval_bins_adj <- p.adjust(mcols(bc1f1_male_samples_2groups_pval_bins)[,1],"fdr")
mcols(bc1f1_male_samples_2groups_pval_bins) <- data.frame(bulkBC1F1Male_p.adj = bc1f1_male_samples_2groups_pval_bins_adj)

bc1f1_female_samples_2groups_pval_bins_adj <- p.adjust(mcols(bc1f1_samples_dist_female_2groups_pval_bins)[,1],"fdr")
mcols(bc1f1_samples_dist_female_2groups_pval_bins) <- data.frame(bulkBC1F1Female_p.adj = bc1f1_female_samples_2groups_pval_bins_adj)

Bins that show significant difference between Fancm -/- and Fancm +/+ in scCNV:

hist(scCNV_pval_bins_adj)

any(scCNV_pval_bins_adj<0.05)
[1] FALSE

Bins that show significant differences between Fancm -/- and Fancm +/* in bc1f1 males:

hist(bc1f1_male_samples_2groups_pval_bins_adj)

any(bc1f1_male_samples_2groups_pval_bins_adj<0.05)
[1] FALSE

Bins that show significant differences between Fancm -/- and Fancm +/* in bc1f1 males:

hist(bc1f1_female_samples_2groups_pval_bins_adj)

any(bc1f1_female_samples_2groups_pval_bins_adj<0.05)
[1] FALSE

Highlight bins with sig. differences between sample groups

From above histogram plot, there is no significant differences in genetic distances in each chromosome bin between two sample groups in scCNV or Bulk samples.

Sessioninfo

sessionInfo()
R version 4.1.2 (2021-11-01)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Rocky Linux 8.5 (Green Obsidian)

Matrix products: default
BLAS/LAPACK: /usr/lib64/libopenblasp-r0.3.12.so

locale:
 [1] LC_CTYPE=en_AU.UTF-8       LC_NUMERIC=C              
 [3] LC_TIME=en_AU.UTF-8        LC_COLLATE=en_AU.UTF-8    
 [5] LC_MONETARY=en_AU.UTF-8    LC_MESSAGES=en_AU.UTF-8   
 [7] LC_PAPER=en_AU.UTF-8       LC_NAME=C                 
 [9] LC_ADDRESS=C               LC_TELEPHONE=C            
[11] LC_MEASUREMENT=en_AU.UTF-8 LC_IDENTIFICATION=C       

attached base packages:
[1] grid      stats4    stats     graphics  grDevices utils     datasets 
[8] methods   base     

other attached packages:
 [1] statmod_1.4.36              BiocParallel_1.28.3        
 [3] gridExtra_2.3               SummarizedExperiment_1.24.0
 [5] Biobase_2.54.0              GenomicRanges_1.46.1       
 [7] GenomeInfoDb_1.30.1         IRanges_2.28.0             
 [9] S4Vectors_0.32.3            BiocGenerics_0.40.0        
[11] MatrixGenerics_1.6.0        matrixStats_0.61.0         
[13] dplyr_1.0.7                 ggplot2_3.3.5              
[15] comapr_0.99.43              readxl_1.3.1               

loaded via a namespace (and not attached):
  [1] backports_1.4.1          circlize_0.4.13          Hmisc_4.6-0             
  [4] workflowr_1.7.0          BiocFileCache_2.2.1      plyr_1.8.6              
  [7] lazyeval_0.2.2           splines_4.1.2            digest_0.6.29           
 [10] foreach_1.5.2            ensembldb_2.18.3         htmltools_0.5.2         
 [13] fansi_1.0.2              magrittr_2.0.2           checkmate_2.0.0         
 [16] memoise_2.0.1            BSgenome_1.62.0          cluster_2.1.2           
 [19] Biostrings_2.62.0        prettyunits_1.1.1        jpeg_0.1-9              
 [22] colorspace_2.0-2         blob_1.2.2               rappdirs_0.3.3          
 [25] xfun_0.29                crayon_1.4.2             RCurl_1.98-1.5          
 [28] jsonlite_1.7.3           survival_3.2-13          VariantAnnotation_1.40.0
 [31] iterators_1.0.14         glue_1.6.1               gtable_0.3.0            
 [34] zlibbioc_1.40.0          XVector_0.34.0           DelayedArray_0.20.0     
 [37] shape_1.4.6              scales_1.1.1             DBI_1.1.2               
 [40] Rcpp_1.0.8               viridisLite_0.4.0        progress_1.2.2          
 [43] htmlTable_2.4.0          foreign_0.8-81           bit_4.0.4               
 [46] Formula_1.2-4            htmlwidgets_1.5.4        httr_1.4.2              
 [49] RColorBrewer_1.1-2       ellipsis_0.3.2           farver_2.1.0            
 [52] pkgconfig_2.0.3          XML_3.99-0.8             Gviz_1.38.3             
 [55] nnet_7.3-16              dbplyr_2.1.1             utf8_1.2.2              
 [58] tidyselect_1.1.1         labeling_0.4.2           rlang_1.0.0             
 [61] reshape2_1.4.4           later_1.3.0              AnnotationDbi_1.56.2    
 [64] munsell_0.5.0            cellranger_1.1.0         tools_4.1.2             
 [67] cachem_1.0.6             cli_3.1.1                generics_0.1.1          
 [70] RSQLite_2.2.9            evaluate_0.14            stringr_1.4.0           
 [73] fastmap_1.1.0            yaml_2.2.2               knitr_1.37              
 [76] bit64_4.0.5              fs_1.5.2                 purrr_0.3.4             
 [79] KEGGREST_1.34.0          AnnotationFilter_1.18.0  xml2_1.3.3              
 [82] biomaRt_2.50.3           compiler_4.1.2           rstudioapi_0.13         
 [85] plotly_4.10.0            filelock_1.0.2           curl_4.3.2              
 [88] png_0.1-7                tibble_3.1.6             stringi_1.7.6           
 [91] highr_0.9                GenomicFeatures_1.46.4   lattice_0.20-45         
 [94] ProtGenerics_1.26.0      Matrix_1.4-0             vctrs_0.3.8             
 [97] pillar_1.6.5             lifecycle_1.0.1          jquerylib_0.1.4         
[100] GlobalOptions_0.1.2      data.table_1.14.2        bitops_1.0-7            
[103] httpuv_1.6.5             rtracklayer_1.54.0       R6_2.5.1                
[106] BiocIO_1.4.0             latticeExtra_0.6-29      promises_1.2.0.1        
[109] codetools_0.2-18         dichromat_2.0-0          assertthat_0.2.1        
[112] rprojroot_2.0.2          rjson_0.2.21             withr_2.4.3             
[115] GenomicAlignments_1.30.0 Rsamtools_2.10.0         GenomeInfoDbData_1.2.7  
[118] parallel_4.1.2           hms_1.1.1                rpart_4.1-15            
[121] tidyr_1.2.0              rmarkdown_2.11           git2r_0.29.0            
[124] biovizBase_1.42.0        base64enc_0.1-3          restfulr_0.0.13         

devtools::session_info()
─ Session info ───────────────────────────────────────────────────────────────
 setting  value
 version  R version 4.1.2 (2021-11-01)
 os       Rocky Linux 8.5 (Green Obsidian)
 system   x86_64, linux-gnu
 ui       X11
 language (EN)
 collate  en_AU.UTF-8
 ctype    en_AU.UTF-8
 tz       Australia/Melbourne
 date     2022-03-14
 pandoc   2.11.4 @ /usr/lib/rstudio-server/bin/pandoc/ (via rmarkdown)

─ Packages ───────────────────────────────────────────────────────────────────
 package              * version  date (UTC) lib source
 AnnotationDbi          1.56.2   2021-11-09 [1] Bioconductor
 AnnotationFilter       1.18.0   2021-10-26 [1] Bioconductor
 assertthat             0.2.1    2019-03-21 [1] CRAN (R 4.1.2)
 backports              1.4.1    2021-12-13 [1] CRAN (R 4.1.2)
 base64enc              0.1-3    2015-07-28 [1] CRAN (R 4.1.2)
 Biobase              * 2.54.0   2021-10-26 [1] Bioconductor
 BiocFileCache          2.2.1    2022-01-23 [1] Bioconductor
 BiocGenerics         * 0.40.0   2021-10-26 [1] Bioconductor
 BiocIO                 1.4.0    2021-10-26 [1] Bioconductor
 BiocParallel         * 1.28.3   2021-12-09 [1] Bioconductor
 biomaRt                2.50.3   2022-02-03 [1] Bioconductor
 Biostrings             2.62.0   2021-10-26 [1] Bioconductor
 biovizBase             1.42.0   2021-10-26 [1] Bioconductor
 bit                    4.0.4    2020-08-04 [1] CRAN (R 4.1.2)
 bit64                  4.0.5    2020-08-30 [1] CRAN (R 4.1.2)
 bitops                 1.0-7    2021-04-24 [1] CRAN (R 4.1.2)
 blob                   1.2.2    2021-07-23 [1] CRAN (R 4.1.2)
 brio                   1.1.3    2021-11-30 [1] CRAN (R 4.1.0)
 BSgenome               1.62.0   2021-10-26 [1] Bioconductor
 cachem                 1.0.6    2021-08-19 [1] CRAN (R 4.1.0)
 callr                  3.7.0    2021-04-20 [1] CRAN (R 4.1.2)
 cellranger             1.1.0    2016-07-27 [1] CRAN (R 4.1.2)
 checkmate              2.0.0    2020-02-06 [1] CRAN (R 4.1.0)
 circlize               0.4.13   2021-06-09 [1] CRAN (R 4.1.0)
 cli                    3.1.1    2022-01-20 [1] CRAN (R 4.1.2)
 cluster                2.1.2    2021-04-17 [2] CRAN (R 4.1.2)
 codetools              0.2-18   2020-11-04 [2] CRAN (R 4.1.2)
 colorspace             2.0-2    2021-06-24 [1] CRAN (R 4.1.2)
 comapr               * 0.99.43  2022-03-09 [1] Github (ruqianl/comapr@915d97c)
 crayon                 1.4.2    2021-10-29 [1] CRAN (R 4.1.2)
 curl                   4.3.2    2021-06-23 [1] CRAN (R 4.1.2)
 data.table             1.14.2   2021-09-27 [1] CRAN (R 4.1.2)
 DBI                    1.1.2    2021-12-20 [1] CRAN (R 4.1.2)
 dbplyr                 2.1.1    2021-04-06 [1] CRAN (R 4.1.2)
 DelayedArray           0.20.0   2021-10-26 [1] Bioconductor
 desc                   1.4.0    2021-09-28 [1] CRAN (R 4.1.0)
 devtools               2.4.3    2021-11-30 [1] CRAN (R 4.1.0)
 dichromat              2.0-0    2013-01-24 [1] CRAN (R 4.1.0)
 digest                 0.6.29   2021-12-01 [1] CRAN (R 4.1.2)
 dplyr                * 1.0.7    2021-06-18 [1] CRAN (R 4.1.2)
 ellipsis               0.3.2    2021-04-29 [1] CRAN (R 4.1.2)
 ensembldb              2.18.3   2022-01-13 [1] Bioconductor
 evaluate               0.14     2019-05-28 [1] CRAN (R 4.1.2)
 fansi                  1.0.2    2022-01-14 [1] CRAN (R 4.1.2)
 farver                 2.1.0    2021-02-28 [1] CRAN (R 4.1.2)
 fastmap                1.1.0    2021-01-25 [1] CRAN (R 4.1.2)
 filelock               1.0.2    2018-10-05 [1] CRAN (R 4.1.0)
 foreach                1.5.2    2022-02-02 [1] CRAN (R 4.1.0)
 foreign                0.8-81   2020-12-22 [2] CRAN (R 4.1.2)
 Formula                1.2-4    2020-10-16 [1] CRAN (R 4.1.0)
 fs                     1.5.2    2021-12-08 [1] CRAN (R 4.1.2)
 generics               0.1.1    2021-10-25 [1] CRAN (R 4.1.2)
 GenomeInfoDb         * 1.30.1   2022-01-30 [1] Bioconductor
 GenomeInfoDbData       1.2.7    2022-01-28 [1] Bioconductor
 GenomicAlignments      1.30.0   2021-10-26 [1] Bioconductor
 GenomicFeatures        1.46.4   2022-01-20 [1] Bioconductor
 GenomicRanges        * 1.46.1   2021-11-18 [1] Bioconductor
 ggplot2              * 3.3.5    2021-06-25 [1] CRAN (R 4.1.2)
 git2r                  0.29.0   2021-11-22 [1] CRAN (R 4.1.2)
 GlobalOptions          0.1.2    2020-06-10 [1] CRAN (R 4.1.0)
 glue                   1.6.1    2022-01-22 [1] CRAN (R 4.1.2)
 gridExtra            * 2.3      2017-09-09 [1] CRAN (R 4.1.0)
 gtable                 0.3.0    2019-03-25 [1] CRAN (R 4.1.2)
 Gviz                   1.38.3   2022-01-23 [1] Bioconductor
 highr                  0.9      2021-04-16 [1] CRAN (R 4.1.2)
 Hmisc                  4.6-0    2021-10-07 [1] CRAN (R 4.1.0)
 hms                    1.1.1    2021-09-26 [1] CRAN (R 4.1.2)
 htmlTable              2.4.0    2022-01-04 [1] CRAN (R 4.1.0)
 htmltools              0.5.2    2021-08-25 [1] CRAN (R 4.1.2)
 htmlwidgets            1.5.4    2021-09-08 [1] CRAN (R 4.1.0)
 httpuv                 1.6.5    2022-01-05 [1] CRAN (R 4.1.2)
 httr                   1.4.2    2020-07-20 [1] CRAN (R 4.1.2)
 IRanges              * 2.28.0   2021-10-26 [1] Bioconductor
 iterators              1.0.14   2022-02-05 [1] CRAN (R 4.1.0)
 jpeg                   0.1-9    2021-07-24 [1] CRAN (R 4.1.0)
 jquerylib              0.1.4    2021-04-26 [1] CRAN (R 4.1.2)
 jsonlite               1.7.3    2022-01-17 [1] CRAN (R 4.1.2)
 KEGGREST               1.34.0   2021-10-26 [1] Bioconductor
 knitr                  1.37     2021-12-16 [1] CRAN (R 4.1.0)
 labeling               0.4.2    2020-10-20 [1] CRAN (R 4.1.2)
 later                  1.3.0    2021-08-18 [1] CRAN (R 4.1.0)
 lattice                0.20-45  2021-09-22 [2] CRAN (R 4.1.2)
 latticeExtra           0.6-29   2019-12-19 [1] CRAN (R 4.1.0)
 lazyeval               0.2.2    2019-03-15 [1] CRAN (R 4.1.0)
 lifecycle              1.0.1    2021-09-24 [1] CRAN (R 4.1.2)
 magrittr               2.0.2    2022-01-26 [1] CRAN (R 4.1.2)
 Matrix                 1.4-0    2021-12-08 [1] CRAN (R 4.1.2)
 MatrixGenerics       * 1.6.0    2021-10-26 [1] Bioconductor
 matrixStats          * 0.61.0   2021-09-17 [1] CRAN (R 4.1.2)
 memoise                2.0.1    2021-11-26 [1] CRAN (R 4.1.0)
 munsell                0.5.0    2018-06-12 [1] CRAN (R 4.1.2)
 nnet                   7.3-16   2021-05-03 [2] CRAN (R 4.1.2)
 pillar                 1.6.5    2022-01-25 [1] CRAN (R 4.1.2)
 pkgbuild               1.3.1    2021-12-20 [1] CRAN (R 4.1.0)
 pkgconfig              2.0.3    2019-09-22 [1] CRAN (R 4.1.2)
 pkgload                1.2.4    2021-11-30 [1] CRAN (R 4.1.0)
 plotly                 4.10.0   2021-10-09 [1] CRAN (R 4.1.0)
 plyr                   1.8.6    2020-03-03 [1] CRAN (R 4.1.0)
 png                    0.1-7    2013-12-03 [1] CRAN (R 4.1.0)
 prettyunits            1.1.1    2020-01-24 [1] CRAN (R 4.1.2)
 processx               3.5.2    2021-04-30 [1] CRAN (R 4.1.2)
 progress               1.2.2    2019-05-16 [1] CRAN (R 4.1.2)
 promises               1.2.0.1  2021-02-11 [1] CRAN (R 4.1.0)
 ProtGenerics           1.26.0   2021-10-26 [1] Bioconductor
 ps                     1.6.0    2021-02-28 [1] CRAN (R 4.1.2)
 purrr                  0.3.4    2020-04-17 [1] CRAN (R 4.1.2)
 R6                     2.5.1    2021-08-19 [1] CRAN (R 4.1.2)
 rappdirs               0.3.3    2021-01-31 [1] CRAN (R 4.1.2)
 RColorBrewer           1.1-2    2014-12-07 [1] CRAN (R 4.1.2)
 Rcpp                   1.0.8    2022-01-13 [1] CRAN (R 4.1.2)
 RCurl                  1.98-1.5 2021-09-17 [1] CRAN (R 4.1.0)
 readxl               * 1.3.1    2019-03-13 [1] CRAN (R 4.1.2)
 remotes                2.4.2    2021-11-30 [1] CRAN (R 4.1.0)
 reshape2               1.4.4    2020-04-09 [1] CRAN (R 4.1.0)
 restfulr               0.0.13   2017-08-06 [1] CRAN (R 4.1.0)
 rjson                  0.2.21   2022-01-09 [1] CRAN (R 4.1.0)
 rlang                  1.0.0    2022-01-26 [1] CRAN (R 4.1.2)
 rmarkdown              2.11     2021-09-14 [1] CRAN (R 4.1.2)
 rpart                  4.1-15   2019-04-12 [2] CRAN (R 4.1.2)
 rprojroot              2.0.2    2020-11-15 [1] CRAN (R 4.1.0)
 Rsamtools              2.10.0   2021-10-26 [1] Bioconductor
 RSQLite                2.2.9    2021-12-06 [1] CRAN (R 4.1.0)
 rstudioapi             0.13     2020-11-12 [1] CRAN (R 4.1.2)
 rtracklayer            1.54.0   2021-10-26 [1] Bioconductor
 S4Vectors            * 0.32.3   2021-11-21 [1] Bioconductor
 scales                 1.1.1    2020-05-11 [1] CRAN (R 4.1.2)
 sessioninfo            1.2.2    2021-12-06 [1] CRAN (R 4.1.0)
 shape                  1.4.6    2021-05-19 [1] CRAN (R 4.1.0)
 statmod              * 1.4.36   2021-05-10 [1] CRAN (R 4.1.2)
 stringi                1.7.6    2021-11-29 [1] CRAN (R 4.1.0)
 stringr                1.4.0    2019-02-10 [1] CRAN (R 4.1.0)
 SummarizedExperiment * 1.24.0   2021-10-26 [1] Bioconductor
 survival               3.2-13   2021-08-24 [2] CRAN (R 4.1.2)
 testthat               3.1.2    2022-01-20 [1] CRAN (R 4.1.0)
 tibble                 3.1.6    2021-11-07 [1] CRAN (R 4.1.2)
 tidyr                  1.2.0    2022-02-01 [1] CRAN (R 4.1.0)
 tidyselect             1.1.1    2021-04-30 [1] CRAN (R 4.1.2)
 usethis                2.1.5    2021-12-09 [1] CRAN (R 4.1.0)
 utf8                   1.2.2    2021-07-24 [1] CRAN (R 4.1.2)
 VariantAnnotation      1.40.0   2021-10-26 [1] Bioconductor
 vctrs                  0.3.8    2021-04-29 [1] CRAN (R 4.1.2)
 viridisLite            0.4.0    2021-04-13 [1] CRAN (R 4.1.2)
 withr                  2.4.3    2021-11-30 [1] CRAN (R 4.1.2)
 workflowr              1.7.0    2021-12-21 [1] CRAN (R 4.1.2)
 xfun                   0.29     2021-12-14 [1] CRAN (R 4.1.2)
 XML                    3.99-0.8 2021-09-17 [1] CRAN (R 4.1.0)
 xml2                   1.3.3    2021-11-30 [1] CRAN (R 4.1.0)
 XVector                0.34.0   2021-10-26 [1] Bioconductor
 yaml                   2.2.2    2022-01-25 [1] CRAN (R 4.1.2)
 zlibbioc               1.40.0   2021-10-26 [1] Bioconductor

 [1] /mnt/beegfs/mccarthy/backed_up/general/rlyu/Software/Rlibs/4.1
 [2] /opt/R/4.1.2/lib/R/library

──────────────────────────────────────────────────────────────────────────────