Last updated: 2025-05-01

Checks: 7 0

Knit directory: ATAC_learning/

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


Great! Since the R Markdown file has been committed to the Git repository, you know the exact version of the code that produced these results.

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(20231016) 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.

Great! You are using Git for version control. Tracking code development and connecting the code version to the results is critical for reproducibility.

The results in this page were generated with repository version cfc813a. See the Past versions tab to see a history of the changes made to the R Markdown and HTML files.

Note that you need to be careful to ensure that all relevant files for the analysis have been committed to Git prior to generating the results (you can use wflow_publish or wflow_git_commit). workflowr only checks the R Markdown file, but you know if there are other scripts or data files that it depends on. Below is the status of the Git repository when the results were generated:


Ignored files:
    Ignored:    .RData
    Ignored:    .Rhistory
    Ignored:    .Rproj.user/
    Ignored:    data/ACresp_SNP_table.csv
    Ignored:    data/ARR_SNP_table.csv
    Ignored:    data/All_merged_peaks.tsv
    Ignored:    data/CAD_gwas_dataframe.RDS
    Ignored:    data/CTX_SNP_table.csv
    Ignored:    data/Collapsed_expressed_NG_peak_table.csv
    Ignored:    data/DEG_toplist_sep_n45.RDS
    Ignored:    data/FRiP_first_run.txt
    Ignored:    data/Final_four_data/
    Ignored:    data/Frip_1_reads.csv
    Ignored:    data/Frip_2_reads.csv
    Ignored:    data/Frip_3_reads.csv
    Ignored:    data/Frip_4_reads.csv
    Ignored:    data/Frip_5_reads.csv
    Ignored:    data/Frip_6_reads.csv
    Ignored:    data/GO_KEGG_analysis/
    Ignored:    data/HF_SNP_table.csv
    Ignored:    data/Ind1_75DA24h_dedup_peaks.csv
    Ignored:    data/Ind1_TSS_peaks.RDS
    Ignored:    data/Ind1_firstfragment_files.txt
    Ignored:    data/Ind1_fragment_files.txt
    Ignored:    data/Ind1_peaks_list.RDS
    Ignored:    data/Ind1_summary.txt
    Ignored:    data/Ind2_TSS_peaks.RDS
    Ignored:    data/Ind2_fragment_files.txt
    Ignored:    data/Ind2_peaks_list.RDS
    Ignored:    data/Ind2_summary.txt
    Ignored:    data/Ind3_TSS_peaks.RDS
    Ignored:    data/Ind3_fragment_files.txt
    Ignored:    data/Ind3_peaks_list.RDS
    Ignored:    data/Ind3_summary.txt
    Ignored:    data/Ind4_79B24h_dedup_peaks.csv
    Ignored:    data/Ind4_TSS_peaks.RDS
    Ignored:    data/Ind4_V24h_fraglength.txt
    Ignored:    data/Ind4_fragment_files.txt
    Ignored:    data/Ind4_fragment_filesN.txt
    Ignored:    data/Ind4_peaks_list.RDS
    Ignored:    data/Ind4_summary.txt
    Ignored:    data/Ind5_TSS_peaks.RDS
    Ignored:    data/Ind5_fragment_files.txt
    Ignored:    data/Ind5_fragment_filesN.txt
    Ignored:    data/Ind5_peaks_list.RDS
    Ignored:    data/Ind5_summary.txt
    Ignored:    data/Ind6_TSS_peaks.RDS
    Ignored:    data/Ind6_fragment_files.txt
    Ignored:    data/Ind6_peaks_list.RDS
    Ignored:    data/Ind6_summary.txt
    Ignored:    data/Knowles_4.RDS
    Ignored:    data/Knowles_5.RDS
    Ignored:    data/Knowles_6.RDS
    Ignored:    data/LiSiLTDNRe_TE_df.RDS
    Ignored:    data/MI_gwas.RDS
    Ignored:    data/SNP_GWAS_PEAK_MRC_id
    Ignored:    data/SNP_GWAS_PEAK_MRC_id.csv
    Ignored:    data/SNP_gene_cat_list.tsv
    Ignored:    data/SNP_supp_schneider.RDS
    Ignored:    data/TE_info/
    Ignored:    data/TFmapnames.RDS
    Ignored:    data/all_TSSE_scores.RDS
    Ignored:    data/all_four_filtered_counts.txt
    Ignored:    data/aln_run1_results.txt
    Ignored:    data/anno_ind1_DA24h.RDS
    Ignored:    data/anno_ind4_V24h.RDS
    Ignored:    data/annotated_gwas_SNPS.csv
    Ignored:    data/background_n45_he_peaks.RDS
    Ignored:    data/cardiac_muscle_FRIP.csv
    Ignored:    data/cardiomyocyte_FRIP.csv
    Ignored:    data/col_ng_peak.csv
    Ignored:    data/cormotif_full_4_run.RDS
    Ignored:    data/cormotif_full_4_run_he.RDS
    Ignored:    data/cormotif_full_6_run.RDS
    Ignored:    data/cormotif_full_6_run_he.RDS
    Ignored:    data/cormotif_probability_45_list.csv
    Ignored:    data/cormotif_probability_45_list_he.csv
    Ignored:    data/cormotif_probability_all_6_list.csv
    Ignored:    data/cormotif_probability_all_6_list_he.csv
    Ignored:    data/datasave.RDS
    Ignored:    data/embryo_heart_FRIP.csv
    Ignored:    data/enhancer_list_ENCFF126UHK.bed
    Ignored:    data/enhancerdata/
    Ignored:    data/filt_Peaks_efit2.RDS
    Ignored:    data/filt_Peaks_efit2_bl.RDS
    Ignored:    data/filt_Peaks_efit2_n45.RDS
    Ignored:    data/first_Peaksummarycounts.csv
    Ignored:    data/first_run_frag_counts.txt
    Ignored:    data/full_bedfiles/
    Ignored:    data/gene_ref.csv
    Ignored:    data/gwas_1_dataframe.RDS
    Ignored:    data/gwas_2_dataframe.RDS
    Ignored:    data/gwas_3_dataframe.RDS
    Ignored:    data/gwas_4_dataframe.RDS
    Ignored:    data/gwas_5_dataframe.RDS
    Ignored:    data/high_conf_peak_counts.csv
    Ignored:    data/high_conf_peak_counts.txt
    Ignored:    data/high_conf_peaks_bl_counts.txt
    Ignored:    data/high_conf_peaks_counts.txt
    Ignored:    data/hits_files/
    Ignored:    data/hyper_files/
    Ignored:    data/hypo_files/
    Ignored:    data/ind1_DA24hpeaks.RDS
    Ignored:    data/ind1_TSSE.RDS
    Ignored:    data/ind2_TSSE.RDS
    Ignored:    data/ind3_TSSE.RDS
    Ignored:    data/ind4_TSSE.RDS
    Ignored:    data/ind4_V24hpeaks.RDS
    Ignored:    data/ind5_TSSE.RDS
    Ignored:    data/ind6_TSSE.RDS
    Ignored:    data/initial_complete_stats_run1.txt
    Ignored:    data/left_ventricle_FRIP.csv
    Ignored:    data/median_24_lfc.RDS
    Ignored:    data/median_3_lfc.RDS
    Ignored:    data/mergedPeads.gff
    Ignored:    data/mergedPeaks.gff
    Ignored:    data/motif_list_full
    Ignored:    data/motif_list_n45
    Ignored:    data/motif_list_n45.RDS
    Ignored:    data/multiqc_fastqc_run1.txt
    Ignored:    data/multiqc_fastqc_run2.txt
    Ignored:    data/multiqc_genestat_run1.txt
    Ignored:    data/multiqc_genestat_run2.txt
    Ignored:    data/my_hc_filt_counts.RDS
    Ignored:    data/my_hc_filt_counts_n45.RDS
    Ignored:    data/n45_bedfiles/
    Ignored:    data/n45_files
    Ignored:    data/other_papers/
    Ignored:    data/peakAnnoList_1.RDS
    Ignored:    data/peakAnnoList_2.RDS
    Ignored:    data/peakAnnoList_24_full.RDS
    Ignored:    data/peakAnnoList_24_n45.RDS
    Ignored:    data/peakAnnoList_3.RDS
    Ignored:    data/peakAnnoList_3_full.RDS
    Ignored:    data/peakAnnoList_3_n45.RDS
    Ignored:    data/peakAnnoList_4.RDS
    Ignored:    data/peakAnnoList_5.RDS
    Ignored:    data/peakAnnoList_6.RDS
    Ignored:    data/peakAnnoList_Eight.RDS
    Ignored:    data/peakAnnoList_full_motif.RDS
    Ignored:    data/peakAnnoList_n45_motif.RDS
    Ignored:    data/siglist_full.RDS
    Ignored:    data/siglist_n45.RDS
    Ignored:    data/summarized_peaks_dataframe.txt
    Ignored:    data/summary_peakIDandReHeat.csv
    Ignored:    data/test.list.RDS
    Ignored:    data/testnames.txt
    Ignored:    data/toplist_6.RDS
    Ignored:    data/toplist_full.RDS
    Ignored:    data/toplist_full_DAR_6.RDS
    Ignored:    data/toplist_n45.RDS
    Ignored:    data/trimmed_seq_length.csv
    Ignored:    data/unclassified_full_set_peaks.RDS
    Ignored:    data/unclassified_n45_set_peaks.RDS
    Ignored:    data/xstreme/

Untracked files:
    Untracked:  analysis/Expressed_RNA_associations.Rmd
    Untracked:  analysis/LFC_corr.Rmd
    Untracked:  analysis/SVA.Rmd
    Untracked:  analysis/Tan2020.Rmd
    Untracked:  analysis/my_hc_filt_counts.csv
    Untracked:  code/IGV_snapshot_code.R
    Untracked:  code/LongDARlist.R
    Untracked:  code/just_for_Fun.R
    Untracked:  output/cormotif_probability_45_list.csv
    Untracked:  output/cormotif_probability_all_6_list.csv
    Untracked:  setup.RData

Unstaged changes:
    Modified:   ATAC_learning.Rproj
    Modified:   analysis/Correlation_of_SNPnPEAK.Rmd
    Modified:   analysis/GO_KEGG_analysis.Rmd
    Modified:   analysis/Raodah_mycount.Rmd
    Modified:   analysis/TE_analysis_ff.Rmd
    Modified:   analysis/final_plot_attempt.Rmd

Note that any generated files, e.g. HTML, png, CSS, etc., are not included in this status report because it is ok for generated content to have uncommitted changes.


These are the previous versions of the repository in which changes were made to the R Markdown (analysis/Figure_3.Rmd) and HTML (docs/Figure_3.html) files. If you’ve configured a remote Git repository (see ?wflow_git_remote), click on the hyperlinks in the table below to view the files as they were in that past version.

File Version Author Date Message
html 18684b9 reneeisnowhere 2025-04-02 Build site.
html 5d30139 E. Renee Matthews 2025-02-24 Build site.
html df8f6ef E. Renee Matthews 2025-02-24 Build site.
Rmd 24b7203 E. Renee Matthews 2025-02-24 taking out a leftover data frame, adding in image
html d4442e0 E. Renee Matthews 2025-02-24 Build site.
Rmd be96ed5 E. Renee Matthews 2025-02-24 first commit
Rmd 8c12c80 E. Renee Matthews 2025-02-24 first commit

packages
library(tidyverse)
library(cowplot)
library(kableExtra)
library(broom)
library(RColorBrewer)
library(ChIPseeker)
library("TxDb.Hsapiens.UCSC.hg38.knownGene")
library("org.Hs.eg.db")
library(rtracklayer)
library(edgeR)
library(ggfortify)
library(limma)
library(readr)
library(BiocGenerics)
library(gridExtra)
library(VennDiagram)
library(scales)
library(Cormotif)
library(BiocParallel)
library(ggpubr)
library(devtools)
library(JASPAR2022)
library(TFBSTools)
library(MotifDb)
library(BSgenome.Hsapiens.UCSC.hg38)
library(data.table)

Data loading

EAR_close_xstreme <-
  readRDS("data/Final_four_data/xstreme/EAR_close_xstreme.RDS")%>%
  slice_head(n = length(.$ID)-3)
EAR_open_xstreme <- 
  readRDS("data/Final_four_data/xstreme/EAR_open_xstreme.RDS")%>%
  slice_head(n = length(.$ID)-3)
ESR_open_xstreme <- 
  readRDS("data/Final_four_data/xstreme/ESR_open_xstreme.RDS")%>%
  slice_head(n = length(.$ID)-3)
ESR_close_xstreme <- 
  readRDS("data/Final_four_data/xstreme/ESR_close_xstreme.RDS")%>%
  slice_head(n = length(.$ID)-3)
ESR_OC_xstreme <- 
  readRDS("data/Final_four_data/xstreme/ESR_OC_xstreme.RDS")%>%
  slice_head(n = length(.$ID)-3)
ESR_opcl_xstreme <- 
  readRDS("data/Final_four_data/xstreme/xstreme_ESR_opcl200.RDS")%>%
  slice_head(n = length(.$ID)-3)
ESR_clop_xstreme <- 
  readRDS("data/Final_four_data/xstreme/xstreme_ESR_clop200.RDS")%>%
  slice_head(n = length(.$ID)-3)


LR_close_xstreme <-
  readRDS("data/Final_four_data/xstreme/LR_close_xstreme.RDS")%>%
  slice_head(n = length(.$ID)-3)
LR_open_xstreme <-
  readRDS("data/Final_four_data/xstreme/LR_open_10h_xstreme.RDS")%>%
  slice_head(n = length(.$ID)-3)
LR_open_10h_xstreme <-
  readRDS("data/Final_four_data/xstreme/LR_open_10h_xstreme.RDS")%>%
  slice_head(n = length(.$ID)-3)

EAR_close_200xstreme <-
  readRDS("data/Final_four_data/xstreme/xstreme_EAR_close200.RDS")%>%
  slice_head(n = length(.$ID)-3)
EAR_open_200xstreme <- 
  readRDS("data/Final_four_data/xstreme/xstreme_EAR_open200.RDS")%>%
  slice_head(n = length(.$ID)-3)
ESR_open_200xstreme <- 
  readRDS("data/Final_four_data/xstreme/xstreme_ESR_open200.RDS")%>%
  slice_head(n = length(.$ID)-3)

ESR_close_200xstreme <- 
  readRDS("data/Final_four_data/xstreme/xstreme_ESR_close200.RDS")%>%
  slice_head(n = length(.$ID)-3)
ESR_OC_xstreme <-
  readRDS("data/Final_four_data/xstreme/xstreme_LR_open200.RDS")%>%
  slice_head(n = length(.$ID)-3)
LR_close_200xstreme <-
  readRDS("data/Final_four_data/xstreme/xstreme_LR_close200.RDS")%>%
  slice_head(n = length(.$ID)-3)
LR_open_200xstreme <-
  readRDS("data/Final_four_data/xstreme/xstreme_LR_open200.RDS")%>%
  slice_head(n = length(.$ID)-3)
#### full sequence sea out
sea_EAR_open <- readRDS("data/Final_four_data/xstreme/sea_EAR_open.RDS")%>%
  slice_head(n = length(.$ID)-3)
sea_EAR_close <- readRDS("data/Final_four_data/xstreme/sea_EAR_close.RDS")%>%
  slice_head(n = length(.$ID)-3)
sea_ESR_close <- readRDS("data/Final_four_data/xstreme/sea_ESR_close.RDS")
sea_ESR_open <- readRDS("data/Final_four_data/xstreme/sea_ESR_open.RDS")#%>%
  # slice_head(n = length(.$ID)-3)
 
sea_ESR_OC <- readRDS("data/Final_four_data/xstreme/sea_ESR_OC.RDS")%>%
  slice_head(n = length(.$ID)-3)
sea_LR_open <- readRDS("data/Final_four_data/xstreme/sea_LR_open_10h.RDS")%>%
  slice_head(n = length(.$ID)-3)
sea_LR_close <- readRDS("data/Final_four_data/xstreme/sea_LR_close.RDS")%>%
  slice_head(n = length(.$ID)-3)

sea_LR_open <- readRDS("data/Final_four_data/xstreme/sea_LR_open_10h.RDS")%>%
  slice_head(n = length(.$ID)-3)


sea_EAR_open_200 <- readRDS("data/Final_four_data/xstreme/sea_EAR_open_200.RDS")%>%
  slice_head(n = length(.$ID)-3)
sea_EAR_close_200 <- readRDS("data/Final_four_data/xstreme/sea_EAR_close_200.RDS")%>%
  slice_head(n = length(.$ID)-3)
sea_ESR_close_200 <- readRDS("data/Final_four_data/xstreme/sea_ESR_close_200.RDS")%>%
  slice_head(n = length(.$ID)-3)
sea_ESR_open_200 <- readRDS("data/Final_four_data/xstreme/sea_ESR_open_200.RDS")%>%
  slice_head(n = length(.$ID)-3)
sea_ESR_opcl_200 <- readRDS("data/Final_four_data/xstreme/sea_ESR_opcl_200.RDS")%>%
  slice_head(n = length(.$ID)-3)

sea_ESR_clop_200 <- readRDS("data/Final_four_data/xstreme/sea_ESR_clop_200.RDS")%>%
  slice_head(n = length(.$ID)-3)

sea_LR_open_200 <- readRDS("data/Final_four_data/xstreme/sea_LR_open_200.RDS")%>%
  slice_head(n = length(.$ID)-3)
sea_LR_close_200 <- readRDS("data/Final_four_data/xstreme/sea_LR_close_200.RDS")%>%
  slice_head(n = length(.$ID)-3)


sea_EAR_open_200_p2 <- readRDS("data/Final_four_data/xstreme/sea_EAR_open_200_p2.RDS")%>%
  slice_head(n = length(.$ID)-3)
sea_EAR_close_200_p2 <- readRDS("data/Final_four_data/xstreme/sea_EAR_close_200_p2.RDS")%>%
  slice_head(n = length(.$ID)-3)
sea_ESR_close_200_p2 <- readRDS("data/Final_four_data/xstreme/sea_ESR_close_200_p2.RDS")%>%
  slice_head(n = length(.$ID)-3)
sea_ESR_open_200_p2 <- readRDS("data/Final_four_data/xstreme/sea_ESR_open_200_p2.RDS")%>%
  slice_head(n = length(.$ID)-3)
sea_ESR_opcl_200_p2 <- readRDS("data/Final_four_data/xstreme/sea_ESR_opcl_200_p2.RDS")%>%
  slice_head(n = length(.$ID)-3)
sea_ESR_clop_200_p2 <- readRDS("data/Final_four_data/xstreme/sea_ESR_clop_200_p2.RDS")%>%
  slice_head(n = length(.$ID)-3)

sea_LR_open_200_p2 <- readRDS("data/Final_four_data/xstreme/sea_LR_open_200_p2.RDS")%>%
  slice_head(n = length(.$ID)-3)
sea_LR_close_200_p2 <- readRDS("data/Final_four_data/xstreme/sea_LR_close_200_p2.RDS")%>%
  slice_head(n = length(.$ID)-3)

Figure 3:

knitr::include_graphics("assets/Figure\ 3.png", error=FALSE)

Version Author Date
ca5c73f E. Renee Matthews 2025-02-26
50f3de9 E. Renee Matthews 2025-02-21
knitr::include_graphics("docs/assets/Figure\ 3.png",error = FALSE)

mrc_palette <- c(
    "EAR_open" = "#F8766D",
    "EAR_close" = "#f6483c",
    "ESR_open" = "#7CAE00",
    "ESR_close" = "#587b00",
    "ESR_C"="grey40",
     "ESR_opcl"="grey40",
    "ESR_D"="tan",
     "ESR_clop"="tan",
     "ESR_OC" = "#6a9500",
     "LR_open" = "#00BFC4",
     "LR_close" = "#008d91",
     "NR" = "#C77CFF"
  )

 spd_EARo_200<-EAR_open_200xstreme%>% 
   mutate(CONSENSUS=gsub('[[:digit:]]+-', '', CONSENSUS)) %>% 
  dplyr::filter(EVALUE<0.05) %>% 
  left_join(., (sea_EAR_open_200_p2 %>%
                  anti_join(.,sea_EAR_open_200, by = c("ID"="ID","ALT_ID"="ALT_ID")) %>%
  rbind(sea_EAR_open_200) %>% 
  dplyr::select(DB:LOG_QVALUE)), by= c( "ALT_ID"="ALT_ID", "CONSENSUS"="CONSENSUS","ID"="ID"))%>% 
  separate(SIM_MOTIF, into= c("SIM_MOTIF", "NAME"), sep= " ") %>% 
  mutate(motif_name= gsub("[()]","",NAME), mrc="EAR_open") %>%
  mutate(motif_name=
           if_else(is.na(motif_name)&str_detect(SIM_MOTIF,"^M"),ALT_ID,
           if_else(is.na(motif_name),ID,motif_name))) 
 #### breaks 

spd_EARc_200 <- EAR_close_200xstreme%>% 
   mutate(CONSENSUS=gsub('[[:digit:]]+-', '', CONSENSUS)) %>% 
  dplyr::filter(EVALUE<0.05) %>% 
  left_join(., (sea_EAR_close_200_p2 %>%
                  anti_join(.,sea_EAR_close_200, by = c("ID"="ID","ALT_ID"="ALT_ID")) %>%
  rbind(sea_EAR_close_200) %>% 
  dplyr::select(DB:LOG_QVALUE)), by= c( "ALT_ID"="ALT_ID", "CONSENSUS"="CONSENSUS","ID"="ID"))%>% 
  separate(SIM_MOTIF, into= c("SIM_MOTIF", "NAME"), sep= " ") %>% 
  mutate(motif_name= gsub("[()]","",NAME), mrc="EAR_close") %>%
  mutate(motif_name=
           if_else(is.na(motif_name)&str_detect(SIM_MOTIF,"^M"),ALT_ID,
           if_else(is.na(motif_name),ID,motif_name)))



spd_ESRo_200 <-ESR_open_200xstreme%>%
   mutate(CONSENSUS=gsub('[[:digit:]]+-', '', CONSENSUS)) %>%
  dplyr::filter(EVALUE<0.05) %>%
  left_join(., (sea_ESR_open_200_p2 %>%
                  anti_join(.,sea_ESR_open_200, by = c("ID"="ID","ALT_ID"="ALT_ID")) %>%
  rbind(sea_ESR_open_200) %>% 
  dplyr::select(DB:LOG_QVALUE)), by= c( "ALT_ID"="ALT_ID", "CONSENSUS"="CONSENSUS","ID"="ID"))%>% 
  separate(SIM_MOTIF, into= c("SIM_MOTIF", "NAME"), sep= " ") %>% 
  mutate(motif_name= gsub("[()]","",NAME), mrc="ESR_open") %>%
  mutate(motif_name=
           if_else(is.na(motif_name)&str_detect(SIM_MOTIF,"^M"),ALT_ID,
           if_else(is.na(motif_name),ID,motif_name)))
spd_ESRc_200 <- ESR_close_200xstreme%>% 
   mutate(CONSENSUS=gsub('[[:digit:]]+-', '', CONSENSUS)) %>% 
  dplyr::filter(EVALUE<0.05) %>% 
  left_join(., (sea_ESR_close_200_p2 %>%
                  anti_join(.,sea_ESR_close_200, by = c("ID"="ID","ALT_ID"="ALT_ID")) %>%
  rbind(sea_ESR_close_200) %>% 
  dplyr::select(DB:LOG_QVALUE)), by= c( "ALT_ID"="ALT_ID", "CONSENSUS"="CONSENSUS","ID"="ID"))%>% 
  separate(SIM_MOTIF, into= c("SIM_MOTIF", "NAME"), sep= " ") %>% 
  mutate(motif_name= gsub("[()]","",NAME), mrc="ESR_close") %>%
  mutate(motif_name=
           if_else(is.na(motif_name)&str_detect(SIM_MOTIF,"^M"),ALT_ID,
           if_else(is.na(motif_name),ID,motif_name)))



spd_ESRopcl_200<-ESR_opcl_xstreme%>% 
   mutate(CONSENSUS=gsub('[[:digit:]]+-', '', CONSENSUS)) %>% 
  dplyr::filter(EVALUE<0.05) %>% 
  left_join(., (sea_ESR_opcl_200_p2 %>%
                  anti_join(.,sea_ESR_opcl_200, by = c("ID"="ID","ALT_ID"="ALT_ID")) %>%
  rbind(sea_ESR_opcl_200) %>% 
  dplyr::select(DB:LOG_QVALUE)), by= c( "ALT_ID"="ALT_ID", "CONSENSUS"="CONSENSUS","ID"="ID"))%>% 
  separate(SIM_MOTIF, into= c("SIM_MOTIF", "NAME"), sep= " ") %>% 
  mutate(motif_name= gsub("[()]","",NAME), mrc="ESR_opcl") %>%
  mutate(motif_name=
           if_else(is.na(motif_name)&str_detect(SIM_MOTIF,"^M"),ALT_ID,
           if_else(is.na(motif_name),ID,motif_name)))

#### break for clop!

spd_ESRclop_200<-ESR_clop_xstreme%>% 
   mutate(CONSENSUS=gsub('[[:digit:]]+-', '', CONSENSUS)) %>% 
  dplyr::filter(EVALUE<0.05) %>% 
  left_join(., (sea_ESR_clop_200_p2 %>%
                  anti_join(.,sea_ESR_clop_200, by = c("ID"="ID","ALT_ID"="ALT_ID")) %>%
  rbind(sea_ESR_clop_200) %>% 
  dplyr::select(DB:LOG_QVALUE)), by= c( "ALT_ID"="ALT_ID", "CONSENSUS"="CONSENSUS","ID"="ID"))%>% 
  separate(SIM_MOTIF, into= c("SIM_MOTIF", "NAME"), sep= " ") %>% 
  mutate(motif_name= gsub("[()]","",NAME), mrc="ESR_clop") %>%
  mutate(motif_name=
           if_else(is.na(motif_name)&str_detect(SIM_MOTIF,"^M"),ALT_ID,
           if_else(is.na(motif_name),ID,motif_name))) 


spd_LRo_200 <-LR_open_200xstreme%>%
           mutate(CONSENSUS=gsub('[[:digit:]]+-', '', CONSENSUS)) %>% 
  dplyr::filter(EVALUE<0.05) %>% 
  left_join(., (sea_LR_open_200_p2 %>%
                  anti_join(.,sea_LR_open_200, by = c("ID"="ID","ALT_ID"="ALT_ID")) %>%
  rbind(sea_LR_open_200) %>% 
  dplyr::select(DB:LOG_QVALUE)), by= c( "ALT_ID"="ALT_ID", "CONSENSUS"="CONSENSUS","ID"="ID"))%>% 
  separate(SIM_MOTIF, into= c("SIM_MOTIF", "NAME"), sep= " ") %>% 
  mutate(motif_name= gsub("[()]","",NAME), mrc="LR_open") %>%
  mutate(motif_name=
           if_else(is.na(motif_name)&str_detect(SIM_MOTIF,"^M"),ALT_ID,  if_else(is.na(motif_name),ID,motif_name)))
 

spd_LRc_200 <- LR_close_200xstreme%>% 
   mutate(CONSENSUS=gsub('[[:digit:]]+-', '', CONSENSUS)) %>% 
  dplyr::filter(EVALUE<0.05) %>% 
  left_join(., (sea_LR_close_200_p2 %>%
                  anti_join(.,sea_LR_close_200, by = c("ID"="ID","ALT_ID"="ALT_ID")) %>%
  rbind(sea_LR_close_200) %>% 
  dplyr::select(DB:LOG_QVALUE)), by= c( "ALT_ID"="ALT_ID", "CONSENSUS"="CONSENSUS","ID"="ID"))%>% 
  separate(SIM_MOTIF, into= c("SIM_MOTIF", "NAME"), sep= " ") %>% 
  mutate(motif_name= gsub("[()]","",NAME), mrc="LR_close") %>%
  mutate(motif_name=
           if_else(is.na(motif_name)&str_detect(SIM_MOTIF,"^M"),ALT_ID,
           if_else(is.na(motif_name),ID,motif_name)))


spec_dataframe_200 <- spd_EARo_200 %>% 
  rbind(spd_EARc_200) %>% 
  rbind(spd_ESRo_200) %>%
   rbind(spd_ESRc_200) %>%
  rbind(spd_ESRopcl_200) %>% 
  rbind(spd_ESRclop_200) %>% 
   rbind(spd_LRo_200) %>% 
   rbind(spd_LRc_200)

# spec_dataframe_200 <- readRDS("data/Final_four_data/spec_dataframe_200.RDS")

EAR open

ER_rat <- 1.25
mrc_type <- "EAR_open"

spec_dataframe_200%>% 
  dplyr::filter(mrc==mrc_type) %>% 
  dplyr::filter(ENR_RATIO>ER_rat) %>%
  dplyr::select(RANK,CLUSTER, SITES,SIM_MOTIF,ALT_ID, ID,EVALUE.x, TP:'FP%', motif_name)%>%
  arrange(.,EVALUE.x) %>%
  mutate(log10Evalue= log(EVALUE.x, base = 10)*(-1)) %>% 
  mutate(motif_name=if_else(motif_name=="ELK3",paste(motif_name, RANK, sep="_"),             if_else(str_starts(motif_name,"^Z*"),paste(motif_name, RANK, sep="_"), if_else(motif_name=="Nrf1",paste(motif_name, RANK,sep="_"),motif_name))))%>%
  distinct(CLUSTER,.keep_all = TRUE) %>% 
  slice_head(n=5) %>% 
  ggplot(., aes (y= reorder(motif_name,log10Evalue))) +
  geom_col(aes(x=log10Evalue),fill=mrc_palette[mrc_type]) +
   geom_point(aes(x=`TP%`/1.5), size =4)+
   # geom_line(aes(x=`TP%`,y= motif_name, group=log10Evalue))+
  scale_x_continuous(expand=c (0,.25),sec.axis = sec_axis(transform= ~.*1.5,name="Percent of peaks with motif"))+
  # geom_text(aes())
  theme_classic()+
  ylab("Enriched TF motif")+
  ggtitle(paste( mrc_type,"response peaks(200bp)Enrichment ratio:",ER_rat," merged clusters"))

Version Author Date
d4442e0 E. Renee Matthews 2025-02-24
EAR_close
ER_rat <- 1.25
mrc_type <- "EAR_close"


spec_dataframe_200 %>% 
  dplyr::filter(mrc==mrc_type) %>% 
  # dplyr::filter(ENR_RATIO>ER_rat) %>% 
  dplyr::select(RANK,CLUSTER, SITES,SIM_MOTIF,ALT_ID, ID,EVALUE.x, TP:'FP%', motif_name)%>%
  # arrange(.,EVALUE.x) %>%
  mutate(log10Evalue= log(EVALUE.x, base = 10)*(-1)) %>% 
  distinct(CLUSTER,.keep_all = TRUE) %>% 
  arrange(.,EVALUE.x) %>%
   slice_head(n=5) %>% 
  ggplot(., aes (y= reorder(motif_name,log10Evalue))) +
  geom_col(aes(x=log10Evalue),fill=mrc_palette[mrc_type]) +
   geom_point(aes(x=`TP%`/1.25), size =4)+
   # geom_line(aes(x=`TP%`,y= motif_name, group=log10Evalue))+
  scale_x_continuous(expand=c (0,.25),sec.axis = sec_axis(transform= ~.*1.25,name="Percent of peaks with motif"))+
  # geom_text(aes())
  theme_classic()+
  ylab("Enriched TF motif")+
   ggtitle(paste( mrc_type,"response peaks (200bp) Enrichment ratio: not applied  modified merged clusters"))

Version Author Date
d4442e0 E. Renee Matthews 2025-02-24
ESR_open
ER_rat <- 1.25
mrc_type <- "ESR_open"

spec_dataframe_200 %>% 
  dplyr::filter(mrc=="ESR_open") %>% 
  dplyr::filter(ENR_RATIO>ER_rat) %>% 
  dplyr::select(RANK,CLUSTER, SITES,SIM_MOTIF,ALT_ID, ID,EVALUE.x, TP:'FP%', motif_name)%>%
  arrange(.,EVALUE.x) %>%
  mutate(log10Evalue= log(EVALUE.x, base = 10)*(-1)) %>% 
   mutate(motif_name=
           if_else(str_starts(motif_name,"JUND"),paste(motif_name, RANK, sep="_"),             if_else(str_starts(motif_name,"^ZN*"),paste(motif_name, RANK, sep="_"),    if_else(motif_name=="ZSCAN4", paste(motif_name, RANK,sep="_"),if_else(motif_name=="KLF9",paste(motif_name,RANK,sep="_"), motif_name)))))%>%
  distinct(CLUSTER,.keep_all = TRUE) %>% 
   slice_head(n=5) %>% 
  ggplot(., aes (y= reorder(motif_name,log10Evalue))) +
  geom_col(aes(x=log10Evalue),fill=mrc_palette["ESR_open"]) +
   geom_point(aes(x=`TP%`*4.7), size =4)+
   # geom_line(aes(x=`TP%`,y= motif_name, group=log10Evalue))+
  scale_x_continuous(expand=c (0,.25),sec.axis = sec_axis(transform= ~./4.7,name="Percent of peaks with motif"))+
  # geom_text(aes())
  theme_classic()+
  ylab("Enriched TF motif")+
  ggtitle(paste(mrc_type,"response peaks 200bp Enrichment ratio:",ER_rat," merged motif clusters"))

Version Author Date
d4442e0 E. Renee Matthews 2025-02-24
ESR_close
ER_rat <- 1.25
mrc_type <- "ESR_close"
spec_dataframe_200 %>% 
  dplyr::filter(mrc==mrc_type) %>% 
  dplyr::filter(ENR_RATIO>(ER_rat+.1)) %>% 
  dplyr::select(RANK,CLUSTER, SITES,SIM_MOTIF,ALT_ID, ID,EVALUE.x, TP:'FP%', motif_name)%>%
  arrange(.,EVALUE.x) %>%
  mutate(log10Evalue= log(EVALUE.x, base = 10)*(-1)) %>% 
  mutate(motif_name=if_else(motif_name=="KLF9",paste(motif_name, RANK, sep="_"),             if_else(motif_name=="^ZN*",paste(motif_name, RANK, sep="_"), if_else(motif_name=="ZSCAN4",paste(motif_name, RANK,sep="_"),motif_name))))%>%
  distinct(CLUSTER,.keep_all = TRUE) %>% 
  slice_head(n=5) %>% 
  ggplot(., aes (y= reorder(motif_name,log10Evalue))) +
  geom_col(aes(x=log10Evalue),fill=mrc_palette[mrc_type]) +
   geom_point(aes(x=`TP%`/0.5), size =4)+
   # geom_line(aes(x=`TP%`,y= motif_name, group=log10Evalue))+
  scale_x_continuous(expand=c (0,.25),sec.axis = sec_axis(transform= ~.*0.5,name="Percent of peaks with motif"))+
  # geom_text(aes())
  theme_classic()+
  ylab("Enriched TF motif")+
  ggtitle(paste( mrc_type,"response peaks 200bp Enrichment ratio:",ER_rat+.1," merged motif clusters"))

Version Author Date
d4442e0 E. Renee Matthews 2025-02-24
ESR_opcl {C}
ER_rat <- 1.25
mrc_type <- "ESR_opcl"

spec_dataframe_200 %>% 
  dplyr::filter(mrc==mrc_type) %>% 
  dplyr::filter(ENR_RATIO>(ER_rat)) %>% 
  dplyr::select(RANK,CLUSTER, SITES,SIM_MOTIF,ALT_ID, ID,EVALUE.x, TP:'FP%', motif_name)%>%
  arrange(.,EVALUE.x) %>%
  mutate(log10Evalue= log(EVALUE.x, base = 10)*(-1)) %>% 
  mutate(motif_name=if_else(motif_name=="KLF9",paste(motif_name, RANK, sep="_"),             if_else(motif_name=="^ZN*",paste(motif_name, RANK, sep="_"), if_else(motif_name=="ZSCAN4",paste(motif_name, RANK,sep="_"),motif_name))))%>%
  distinct(CLUSTER,.keep_all = TRUE) %>% 
  slice_head(n=5) %>% 
  ggplot(., aes (y= reorder(motif_name,log10Evalue))) +
  geom_col(aes(x=log10Evalue),fill=mrc_palette[mrc_type]) +
   geom_point(aes(x=`TP%`/3), size =4)+
   # geom_line(aes(x=`TP%`,y= motif_name, group=log10Evalue))+
  scale_x_continuous(expand=c (0,.25),sec.axis = sec_axis(transform= ~.*3,name="Percent of peaks with motif"))+
  # geom_text(aes())
  theme_classic()+
  ylab("Enriched TF motif")+
  ggtitle(paste( mrc_type,"response peaks 200bp Enrichment ratio:",ER_rat," merged motif clusters"))

Version Author Date
d4442e0 E. Renee Matthews 2025-02-24
ESR_clop {D}
ER_rat <- 1.25
mrc_type <- "ESR_clop"

spec_dataframe_200 %>% 
  dplyr::filter(mrc==mrc_type) %>% 
  dplyr::filter(ENR_RATIO>(ER_rat)) %>% 
  dplyr::select(RANK,CLUSTER, SITES,SIM_MOTIF,ALT_ID, ID,EVALUE.x, TP:'FP%', motif_name)%>%
  arrange(.,EVALUE.x) %>%
  mutate(log10Evalue= log(EVALUE.x, base = 10)*(-1)) %>% 
  mutate(motif_name=if_else(motif_name=="KLF9",paste(motif_name, RANK, sep="_"),             if_else(motif_name=="^ZN*",paste(motif_name, RANK, sep="_"), if_else(motif_name=="ZSCAN4",paste(motif_name, RANK,sep="_"),motif_name))))%>%
  distinct(CLUSTER,.keep_all = TRUE) %>% 
  slice_head(n=5) %>% 
  ggplot(., aes (y= reorder(motif_name,log10Evalue))) +
  geom_col(aes(x=log10Evalue),fill=mrc_palette[mrc_type]) +
   geom_point(aes(x=`TP%`*2.3), size =4)+
   # geom_line(aes(x=`TP%`,y= motif_name, group=log10Evalue))+
  scale_x_continuous(expand=c (0,.25),sec.axis = sec_axis(transform= ~./2.3,name="Percent of peaks with motif"))+
  # geom_text(aes())
  theme_classic()+
  ylab("Enriched TF motif")+
  ggtitle(paste( mrc_type,"response peaks 200bp Enrichment ratio:",ER_rat," merged motif clusters"))

Version Author Date
d4442e0 E. Renee Matthews 2025-02-24
LR_open
ER_rat <- 1.25
mrc_type <- "LR_open"

spec_dataframe_200 %>% 
  dplyr::filter(mrc==mrc_type) %>% 
  dplyr::filter(ENR_RATIO>ER_rat) %>% 
  dplyr::select(RANK,CLUSTER, SITES,SIM_MOTIF,ALT_ID, ID,EVALUE.x, TP:'FP%', motif_name)%>%
  arrange(.,EVALUE.x) %>%
  mutate(log10Evalue= log(EVALUE.x, base = 10)*(-1)) %>% 
  mutate(motif_name=
           if_else(str_starts(motif_name,"BATF"),paste(motif_name, RANK, sep="_"),             if_else(str_starts(motif_name,"^FO*"),paste(motif_name, RANK, sep="_"),    if_else(motif_name=="ZSCAN4", paste(motif_name, RANK,sep="_"),if_else(motif_name=="KLF9",paste(motif_name,RANK,sep="_"), motif_name)))))%>%
  distinct(CLUSTER,.keep_all = TRUE) %>% 
   slice_head(n=5) %>% 
  ggplot(., aes (y= reorder(motif_name,log10Evalue))) +
  geom_col(aes(x=log10Evalue),fill=mrc_palette[mrc_type]) +
   geom_point(aes(x=`TP%`*5), size =4)+
   # geom_line(aes(x=`TP%`,y= motif_name, group=log10Evalue))+
  scale_x_continuous(expand=c (0,.25),sec.axis = sec_axis(transform= ~./5,name="Percent of peaks with motif"))+
  # geom_text(aes())
  theme_classic()+
  ylab("Enriched TF motif")+
  ggtitle(paste( mrc_type,"response peaks 200 bp Enrichment ratio:",ER_rat," merged motif clusters"))

Version Author Date
d4442e0 E. Renee Matthews 2025-02-24
LR_close
ER_rat <- 1.25
mrc_type <- "LR_close"

spec_dataframe_200 %>% 
  dplyr::filter(mrc==mrc_type) %>% 
  dplyr::filter(ENR_RATIO>ER_rat) %>% 
  dplyr::select(RANK,CLUSTER, SITES,SIM_MOTIF,ALT_ID, ID,EVALUE.x, TP:'FP%', motif_name)%>%
  arrange(.,EVALUE.x) %>%
  mutate(log10Evalue= log(EVALUE.x, base = 10)*(-1)) %>% 
  mutate(motif_name=if_else(motif_name=="KLF9",paste(motif_name, RANK, sep="_"),             if_else(str_starts(motif_name,"^R*"),paste(motif_name, RANK, sep="_"), if_else(motif_name=="PKNOX2",paste(motif_name, RANK,sep="_"),motif_name))))%>%
  distinct(CLUSTER,.keep_all = TRUE) %>% 
  slice_head(n=5) %>% 
  ggplot(., aes (y= reorder(motif_name,log10Evalue))) +
  geom_col(aes(x=log10Evalue),fill=mrc_palette[mrc_type]) +
   geom_point(aes(x=`TP%`/.4), size =4)+
   # geom_line(aes(x=`TP%`,y= motif_name, group=log10Evalue))+
  scale_x_continuous(expand=c (0,.25),sec.axis = sec_axis(transform= ~.*.4,name="Percent of peaks with motif"))+
  # geom_text(aes())
  theme_classic()+
  ylab("Enriched TF motif")+
  ggtitle(paste( mrc_type,"response peaks 200bp Enrichment ratio:",ER_rat," merged motif clusters"))

Version Author Date
d4442e0 E. Renee Matthews 2025-02-24
# spec_dataframe %>% 
#   dplyr::filter(mrc==mrc_type) %>% 
#   dplyr::filter(ENR_RATIO>ER_rat) #%>% 
#   dplyr::select(RANK,CLUSTER, SITES,SIM_MOTIF,ALT_ID, ID,EVALUE, TP:'FP%', motif_name)

How I printed out the consensus motifs for graphing

library(universalmotif)
library(ggseqlogo)
library(motifmatchr)
library(gridExtra)
meme_motifs_EAR_open <- read_meme("C:/Users/renee/ATAC_folder/ATAC_meme_data/200bp/EAR_open_200xstreme/xstreme.txt")
meme_motifs_ESR_open <- read_meme("C:/Users/renee/ATAC_folder/ATAC_meme_data/200bp/ESR_open_200xstreme/xstreme.txt")
meme_motifs_LR_open <- read_meme("C:/Users/renee/ATAC_folder/ATAC_meme_data/200bp/LR_open_200xstreme/xstreme.txt")
meme_motifs_EAR_close <- read_meme("C:/Users/renee/ATAC_folder/ATAC_meme_data/200bp/EAR_close_200xstreme/xstreme.txt")
meme_motifs_ESR_close <- read_meme("C:/Users/renee/ATAC_folder/ATAC_meme_data/200bp/ESR_close_200xstreme/xstreme.txt")
meme_motifs_LR_close <- read_meme("C:/Users/renee/ATAC_folder/ATAC_meme_data/200bp/LR_close_200xstreme/xstreme.txt")
meme_motifs_ESR_opcl <- read_meme("C:/Users/renee/ATAC_folder/ATAC_meme_data/200bp/ESR_C_200xstreme/xstreme.txt")
meme_motifs_ESR_clop <- read_meme("C:/Users/renee/ATAC_folder/ATAC_meme_data/200bp/ESR_D_200xstreme/xstreme.txt")
group_of_memes <- list(EAR_open=meme_motifs_EAR_open,
                    ESR_open=meme_motifs_ESR_open,
                    LR_open=meme_motifs_LR_open,
                    EAR_close=meme_motifs_EAR_close,
                    ESR_close=meme_motifs_ESR_close,
                    LR_close=meme_motifs_LR_close,
                    ESR_opcl=meme_motifs_ESR_opcl,
                    ESR_clop=meme_motifs_ESR_clop)
name_plot <- c("meme_motifs_EAR_open",
                  "meme_motifs_ESR_open",
                    "meme_motifs_LR_open",
                "meme_motifs_EAR_close",
                    "meme_motifs_ESR_close",
                    "meme_motifs_LR_close",
                    "meme_motifs_ESR_opcl",
                    "meme_motifs_ESR_clop")
counter <- 0
for (meme_frame in group_of_memes ){
   counter <- counter +1 
motif_info <- lapply(meme_frame, function(motif) {
  data.frame(
    motif_name = ifelse(is.null(motif@name), NA, motif@name),
    alt_name = ifelse(is.null(motif@altname), NA, motif@altname)  # Handle missing altname
    # Store the position weight matrix (PWM) in a list
    
  )
})
# Combine the individual motif data frames into one long data frame
motif_df <- bind_rows(motif_info)

plots <- lapply(1:nrow(motif_df), function(i) {
  pwm <-meme_frame[[i]]@motif # Extract PWM for each motif
  name <- motif_df$motif_name[i]
  alt_name <- motif_df$alt_name[i]
  
  # Check if the PWM is valid and can be plotted
  if (!is.null(pwm) && is.matrix(pwm)) {
    ggseqlogo::ggseqlogo(pwm,  method="bits") +
      ggtitle(paste("Motif:", name, "\n| Altname:", alt_name)) +
      theme_minimal()
  } else {
    message("Invalid PWM for motif:", name)
    NULL
  }
})
savefile <- paste0("data/Final_four_data/",name_plot[counter],".pdf")
plots_per_page <- 16 
multi_page_grobs <- marrangeGrob(plots, nrow = 4, ncol = 4) 
ggsave(savefile, multi_page_grobs)
grid.draw(multi_page_grobs)
}

sessionInfo()
R version 4.4.2 (2024-10-31 ucrt)
Platform: x86_64-w64-mingw32/x64
Running under: Windows 11 x64 (build 26100)

Matrix products: default


locale:
[1] LC_COLLATE=English_United States.utf8 
[2] LC_CTYPE=English_United States.utf8   
[3] LC_MONETARY=English_United States.utf8
[4] LC_NUMERIC=C                          
[5] LC_TIME=English_United States.utf8    

time zone: America/Chicago
tzcode source: internal

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

other attached packages:
 [1] data.table_1.17.0                       
 [2] BSgenome.Hsapiens.UCSC.hg38_1.4.5       
 [3] BSgenome_1.74.0                         
 [4] BiocIO_1.16.0                           
 [5] MotifDb_1.48.0                          
 [6] Biostrings_2.74.1                       
 [7] XVector_0.46.0                          
 [8] TFBSTools_1.44.0                        
 [9] JASPAR2022_0.99.8                       
[10] BiocFileCache_2.14.0                    
[11] dbplyr_2.5.0                            
[12] devtools_2.4.5                          
[13] usethis_3.1.0                           
[14] ggpubr_0.6.0                            
[15] BiocParallel_1.40.0                     
[16] Cormotif_1.52.0                         
[17] affy_1.84.0                             
[18] scales_1.3.0                            
[19] VennDiagram_1.7.3                       
[20] futile.logger_1.4.3                     
[21] gridExtra_2.3                           
[22] ggfortify_0.4.17                        
[23] edgeR_4.4.2                             
[24] limma_3.62.2                            
[25] rtracklayer_1.66.0                      
[26] org.Hs.eg.db_3.20.0                     
[27] TxDb.Hsapiens.UCSC.hg38.knownGene_3.20.0
[28] GenomicFeatures_1.58.0                  
[29] AnnotationDbi_1.68.0                    
[30] Biobase_2.66.0                          
[31] GenomicRanges_1.58.0                    
[32] GenomeInfoDb_1.42.3                     
[33] IRanges_2.40.1                          
[34] S4Vectors_0.44.0                        
[35] BiocGenerics_0.52.0                     
[36] ChIPseeker_1.42.1                       
[37] RColorBrewer_1.1-3                      
[38] broom_1.0.7                             
[39] kableExtra_1.4.0                        
[40] cowplot_1.1.3                           
[41] lubridate_1.9.4                         
[42] forcats_1.0.0                           
[43] stringr_1.5.1                           
[44] dplyr_1.1.4                             
[45] purrr_1.0.4                             
[46] readr_2.1.5                             
[47] tidyr_1.3.1                             
[48] tibble_3.2.1                            
[49] ggplot2_3.5.1                           
[50] tidyverse_2.0.0                         
[51] workflowr_1.7.1                         

loaded via a namespace (and not attached):
  [1] fs_1.6.5                               
  [2] matrixStats_1.5.0                      
  [3] bitops_1.0-9                           
  [4] DirichletMultinomial_1.48.0            
  [5] enrichplot_1.26.6                      
  [6] httr_1.4.7                             
  [7] profvis_0.4.0                          
  [8] tools_4.4.2                            
  [9] backports_1.5.0                        
 [10] R6_2.6.1                               
 [11] lazyeval_0.2.2                         
 [12] urlchecker_1.0.1                       
 [13] withr_3.0.2                            
 [14] preprocessCore_1.68.0                  
 [15] cli_3.6.4                              
 [16] formatR_1.14                           
 [17] labeling_0.4.3                         
 [18] sass_0.4.9                             
 [19] Rsamtools_2.22.0                       
 [20] systemfonts_1.2.1                      
 [21] yulab.utils_0.2.0                      
 [22] DOSE_4.0.0                             
 [23] svglite_2.1.3                          
 [24] R.utils_2.13.0                         
 [25] sessioninfo_1.2.3                      
 [26] plotrix_3.8-4                          
 [27] rstudioapi_0.17.1                      
 [28] RSQLite_2.3.9                          
 [29] generics_0.1.3                         
 [30] gridGraphics_0.5-1                     
 [31] TxDb.Hsapiens.UCSC.hg19.knownGene_3.2.2
 [32] gtools_3.9.5                           
 [33] car_3.1-3                              
 [34] GO.db_3.20.0                           
 [35] Matrix_1.7-3                           
 [36] abind_1.4-8                            
 [37] R.methodsS3_1.8.2                      
 [38] lifecycle_1.0.4                        
 [39] whisker_0.4.1                          
 [40] yaml_2.3.10                            
 [41] carData_3.0-5                          
 [42] SummarizedExperiment_1.36.0            
 [43] gplots_3.2.0                           
 [44] qvalue_2.38.0                          
 [45] SparseArray_1.6.2                      
 [46] blob_1.2.4                             
 [47] promises_1.3.2                         
 [48] pwalign_1.2.0                          
 [49] crayon_1.5.3                           
 [50] miniUI_0.1.1.1                         
 [51] ggtangle_0.0.6                         
 [52] lattice_0.22-6                         
 [53] annotate_1.84.0                        
 [54] KEGGREST_1.46.0                        
 [55] pillar_1.10.1                          
 [56] knitr_1.49                             
 [57] fgsea_1.32.2                           
 [58] rjson_0.2.23                           
 [59] boot_1.3-31                            
 [60] codetools_0.2-20                       
 [61] fastmatch_1.1-6                        
 [62] glue_1.8.0                             
 [63] getPass_0.2-4                          
 [64] ggfun_0.1.8                            
 [65] remotes_2.5.0                          
 [66] vctrs_0.6.5                            
 [67] png_0.1-8                              
 [68] treeio_1.30.0                          
 [69] poweRlaw_1.0.0                         
 [70] gtable_0.3.6                           
 [71] cachem_1.1.0                           
 [72] xfun_0.51                              
 [73] S4Arrays_1.6.0                         
 [74] mime_0.12                              
 [75] statmod_1.5.0                          
 [76] ellipsis_0.3.2                         
 [77] nlme_3.1-167                           
 [78] ggtree_3.14.0                          
 [79] bit64_4.6.0-1                          
 [80] filelock_1.0.3                         
 [81] rprojroot_2.0.4                        
 [82] bslib_0.9.0                            
 [83] affyio_1.76.0                          
 [84] KernSmooth_2.23-26                     
 [85] splitstackshape_1.4.8                  
 [86] seqLogo_1.72.0                         
 [87] colorspace_2.1-1                       
 [88] DBI_1.2.3                              
 [89] tidyselect_1.2.1                       
 [90] processx_3.8.6                         
 [91] bit_4.6.0                              
 [92] compiler_4.4.2                         
 [93] curl_6.2.1                             
 [94] git2r_0.35.0                           
 [95] xml2_1.3.7                             
 [96] DelayedArray_0.32.0                    
 [97] caTools_1.18.3                         
 [98] callr_3.7.6                            
 [99] digest_0.6.37                          
[100] rmarkdown_2.29                         
[101] htmltools_0.5.8.1                      
[102] pkgconfig_2.0.3                        
[103] MatrixGenerics_1.18.1                  
[104] fastmap_1.2.0                          
[105] rlang_1.1.5                            
[106] htmlwidgets_1.6.4                      
[107] UCSC.utils_1.2.0                       
[108] shiny_1.10.0                           
[109] farver_2.1.2                           
[110] jquerylib_0.1.4                        
[111] jsonlite_1.9.1                         
[112] GOSemSim_2.32.0                        
[113] R.oo_1.27.0                            
[114] RCurl_1.98-1.16                        
[115] magrittr_2.0.3                         
[116] Formula_1.2-5                          
[117] GenomeInfoDbData_1.2.13                
[118] ggplotify_0.1.2                        
[119] patchwork_1.3.0                        
[120] munsell_0.5.1                          
[121] Rcpp_1.0.14                            
[122] ape_5.8-1                              
[123] stringi_1.8.4                          
[124] zlibbioc_1.52.0                        
[125] plyr_1.8.9                             
[126] pkgbuild_1.4.6                         
[127] parallel_4.4.2                         
[128] ggrepel_0.9.6                          
[129] CNEr_1.42.0                            
[130] splines_4.4.2                          
[131] hms_1.1.3                              
[132] locfit_1.5-9.12                        
[133] ps_1.9.0                               
[134] igraph_2.1.4                           
[135] ggsignif_0.6.4                         
[136] reshape2_1.4.4                         
[137] pkgload_1.4.0                          
[138] TFMPvalue_0.0.9                        
[139] futile.options_1.0.1                   
[140] XML_3.99-0.18                          
[141] evaluate_1.0.3                         
[142] lambda.r_1.2.4                         
[143] BiocManager_1.30.25                    
[144] tzdb_0.4.0                             
[145] httpuv_1.6.15                          
[146] xtable_1.8-4                           
[147] restfulr_0.0.15                        
[148] tidytree_0.4.6                         
[149] rstatix_0.7.2                          
[150] later_1.4.1                            
[151] viridisLite_0.4.2                      
[152] aplot_0.2.5                            
[153] memoise_2.0.1                          
[154] GenomicAlignments_1.42.0               
[155] timechange_0.3.0