Skip to content

Commit 41a1b16

Browse files
bschilderclaude
andcommitted
Add pkgdown dark theme and improve vignette eval guards
- Add _pkgdown.yml with echoverse dark theme (bslib + custom CSS) - Organize 48 exports into 9 reference groups - Add has_internet guards to vignette chunks that download data - Keep eval=FALSE for expensive external API calls (annotate_snps) - Fix VignetteIndexEntry in cell_type_specific_epigenomics - Add curl to Suggests for connectivity check Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 5a03395 commit 41a1b16

4 files changed

Lines changed: 226 additions & 52 deletions

File tree

DESCRIPTION

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@ Imports:
5353
IRanges,
5454
rlang
5555
Suggests:
56+
curl,
5657
XGR,
5758
markdown,
5859
rmarkdown,

_pkgdown.yml

Lines changed: 160 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,160 @@
1+
url: https://rajlabmssm.github.io/echoannot/
2+
3+
template:
4+
bootstrap: 5
5+
bslib:
6+
bg: "#1a2744"
7+
fg: "#e8f4f4"
8+
primary: "#4ecdc4"
9+
secondary: "#3a8d8c"
10+
success: "#2ee8d6"
11+
info: "#5bc0be"
12+
code-bg: "#d6e4ee"
13+
code-color: "#1a2744"
14+
border-color: "#2a4060"
15+
link-color: "#4ecdc4"
16+
link-hover-color: "#2ee8d6"
17+
font-size-base: "1rem"
18+
includes:
19+
in_header: |
20+
<style>
21+
.navbar {
22+
background-color: #162038 !important;
23+
border-bottom: 2px solid #4ecdc4;
24+
}
25+
.navbar-brand, .nav-link { color: #e8f4f4 !important; }
26+
.nav-link:hover { color: #2ee8d6 !important; }
27+
.nav-link.active { color: #2ee8d6 !important; border-bottom: 2px solid #2ee8d6; }
28+
pre {
29+
background-color: #d6e4ee !important;
30+
color: #1a2744 !important;
31+
border: none !important;
32+
border-radius: 12px;
33+
margin: 0;
34+
padding: 0.8em 1em;
35+
}
36+
code { color: #1a6b68 !important; border: none !important; }
37+
pre code { color: #1a2744 !important; border: none !important; background: transparent !important; }
38+
pre code span { border: none !important; background: transparent !important; }
39+
.table { color: #e8f4f4 !important; }
40+
.table-striped > tbody > tr:nth-of-type(odd) > * {
41+
background-color: rgba(78, 205, 196, 0.05) !important;
42+
color: #e8f4f4 !important;
43+
}
44+
.table-striped > tbody > tr:nth-of-type(even) > * {
45+
background-color: transparent !important;
46+
color: #e8f4f4 !important;
47+
}
48+
.table > thead { border-bottom: 2px solid #4ecdc4; }
49+
h1, h2, h3, h4, h5, h6 { color: #4ecdc4 !important; }
50+
a { color: #5bc0be; }
51+
a:hover { color: #2ee8d6; }
52+
.card { background-color: #1e3050; border-color: #2a4060; }
53+
.footer { background-color: #162038 !important; border-top: 1px solid #2a4060; }
54+
.page-header { border-bottom: 2px solid #3a8d8c; }
55+
.sourceCode {
56+
background-color: #d6e4ee !important;
57+
border: 1px solid #3a8d8c;
58+
border-radius: 12px !important;
59+
overflow: hidden;
60+
}
61+
.sourceCode code span,
62+
.sourceCode code a {
63+
border: none !important;
64+
outline: none !important;
65+
box-shadow: none !important;
66+
background: transparent !important;
67+
}
68+
</style>
69+
70+
navbar:
71+
structure:
72+
left: [intro, reference, articles, news]
73+
right: [search, github]
74+
components:
75+
github:
76+
icon: fa-github
77+
href: https://github.com/RajLabMSSM/echoannot
78+
79+
articles:
80+
- title: Getting started
81+
contents:
82+
- echoannot
83+
- title: Epigenomics
84+
contents:
85+
- cell_type_specific_epigenomics
86+
87+
reference:
88+
- title: Annotation functions
89+
desc: Annotate SNPs with functional information
90+
contents:
91+
- annotate_snps
92+
- annotate_missense
93+
- annotation_file_name
94+
- title: NOTT2019 data
95+
desc: Brain cell-type-specific epigenomic data from Nott et al. 2019
96+
contents:
97+
- NOTT2019_epigenomic_histograms
98+
- NOTT2019_get_epigenomic_peaks
99+
- NOTT2019_get_interactome
100+
- NOTT2019_get_promoter_interactome_data
101+
- NOTT2019_get_regulatory_regions
102+
- NOTT2019_plac_seq_plot
103+
- get_NOTT2019_superenhancer_interactome
104+
- title: CORCES2020 data
105+
desc: Single-cell epigenomic data from Corces et al. 2020
106+
contents:
107+
- CORCES2020_get_ATAC_peak_overlap
108+
- CORCES2020_get_hichip_fithichip_overlap
109+
- get_CORCES2020_bulkATACseq_peaks
110+
- get_CORCES2020_cicero_coaccessibility
111+
- get_CORCES2020_hichip_fithichip_loop_calls
112+
- get_CORCES2020_scATACseq_celltype_peaks
113+
- get_CORCES2020_scATACseq_peaks
114+
- title: GOSHIFTER
115+
desc: GoShifter enrichment analysis
116+
contents:
117+
- GOSHIFTER
118+
- GOSHIFTER_run
119+
- GOSHIFTER_heatmap
120+
- GOSHIFTER_histograms_SNPgroups
121+
- GOSHIFTER_histograms_pvals
122+
- title: MOTIFBREAKR
123+
desc: Motif disruption analysis
124+
contents:
125+
- MOTIFBREAKR
126+
- MOTIFBREAKR_calc_pvals
127+
- MOTIFBREAKR_filter
128+
- MOTIFBREAKR_plot
129+
- MOTIFBREAKR_summarize
130+
- title: XGR
131+
desc: Genomic region annotation via XGR
132+
contents:
133+
- XGR_enrichment
134+
- XGR_filter_assays
135+
- XGR_filter_sources
136+
- XGR_query
137+
- title: ROADMAP
138+
desc: Roadmap Epigenomics chromatin state annotations
139+
contents:
140+
- ROADMAP_construct_reference
141+
- ROADMAP_query
142+
- title: Plotting
143+
desc: Summary and visualization functions
144+
contents:
145+
- CS_bin_plot
146+
- CS_counts_plot
147+
- super_summary_plot
148+
- peak_overlap_plot
149+
- plot_dataset_overlap
150+
- plot_missense
151+
- convert_plots
152+
- merge_celltype_specific_epigenomics
153+
- title: Utilities
154+
desc: Helper functions
155+
contents:
156+
- add_mb
157+
- granges_overlap
158+
- get_window_limits
159+
- import_ucsc_bigwigs
160+
- test_enrichment
Lines changed: 29 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,22 @@
11
---
2-
title: "Cell-type-specific epigenomics"
3-
author: "<h4>Author: <i>Brian M. Schilder</i></h4>"
2+
title: "Cell-type-specific epigenomics"
3+
author: "<h4>Author: <i>Brian M. Schilder</i></h4>"
44
date: "<h4>Updated: <i>`r format( Sys.Date(), '%b-%d-%Y')`</i></h4>"
55
output:
66
BiocStyle::html_document
77
vignette: >
8-
%\VignetteIndexEntry{echoplot}
8+
%\VignetteIndexEntry{cell_type_specific_epigenomics}
99
%\usepackage[utf8]{inputenc}
1010
%\VignetteEngine{knitr::rmarkdown}
1111
---
1212

1313
```{r setup, echo=FALSE, include=FALSE}
1414
pkg <- read.dcf("../DESCRIPTION", fields = "Package")[1]
1515
library(pkg, character.only = TRUE)
16+
has_internet <- tryCatch(
17+
!is.null(curl::nslookup("github.com", error = FALSE)),
18+
error = function(e) FALSE
19+
)
1620
```
1721

1822
```R
@@ -22,45 +26,45 @@ library(`r pkg`)
2226
## Nott2019
2327

2428
`echoannot` includes data generated by
25-
["Nott2019"](https://doi.org/10.1126/science.aay0793):
29+
["Nott2019"](https://doi.org/10.1126/science.aay0793):
2630

2731
> Nott A, Holtman IR, Coufal NG, ... Glass CK. Brain cell type-specific enhancer-promoter interactome maps and disease-risk association. Science. 2019 Nov 29;366(6469):1134-1139. doi: 10.1126/science.aay0793. Epub 2019 Nov 14. PMID: 31727856; PMCID: PMC7028213.
2832
29-
### Import data
33+
### Import data
3034

31-
```R
35+
```{r nott2019_import, eval=has_internet}
3236
superenhancers <- echoannot::get_NOTT2019_superenhancer_interactome()
3337
enhancers_promoters <- echoannot::NOTT2019_get_promoter_interactome_data()
34-
peaks <- echoannot::NOTT2019_get_epigenomic_peaks()
38+
peaks <- echoannot::NOTT2019_get_epigenomic_peaks()
3539
```
3640

3741

3842
### Plot
3943

40-
```{r, eval=FALSE}
44+
```{r nott2019_plot, eval=has_internet}
4145
dat <- echodata::BST1
4246
histo_out <- echoannot::NOTT2019_epigenomic_histograms(dat = dat)
4347
```
4448

45-
In addition to the plot object,
49+
In addition to the plot object,
4650
tables of both raw read ranges and called peaks are included in the output list.
4751

48-
```{r, eval=FALSE}
52+
```{r nott2019_tables, eval=has_internet}
4953
knitr::kable(head(histo_out$data$raw))
5054
knitr::kable(head(histo_out$data$peaks))
5155
```
5256

53-
57+
5458
## Corces2020
5559

5660
`echoannot` also includes data generated by
5761
["Corces2019"](https://doi.org/10.1038/s41588-020-00721-x):
5862

59-
> Corces, M.R., Shcherbina, A., Kundu, S. et al. Single-cell epigenomic analyses implicate candidate causal variants at inherited risk loci for Alzheimers and Parkinsons diseases. Nat Genet 52, 11581168 (2020). https://doi.org/10.1038/s41588-020-00721-x
63+
> Corces, M.R., Shcherbina, A., Kundu, S. et al. Single-cell epigenomic analyses implicate candidate causal variants at inherited risk loci for Alzheimer's and Parkinson's diseases. Nat Genet 52, 1158-1168 (2020). https://doi.org/10.1038/s41588-020-00721-x
6064
61-
### Import data
65+
### Import data
6266

63-
```R
67+
```{r corces2020_import, eval=has_internet}
6468
bulkATACseq_peaks <- echoannot::get_CORCES2020_bulkATACseq_peaks()
6569
cicero_coaccessibility <- echoannot::get_CORCES2020_cicero_coaccessibility()
6670
hichip_fithichip_loop_calls <- echoannot::get_CORCES2020_hichip_fithichip_loop_calls()
@@ -70,27 +74,29 @@ scATACseq_peaks <- echoannot::get_CORCES2020_scATACseq_peaks()
7074

7175
### Plot
7276

73-
```R
77+
*Note:* This chunk is kept as `eval=FALSE` because it depends on
78+
the `dat` variable from a prior analysis and `ggbio::autoplot`.
79+
80+
```{r corces2020_plot, eval=FALSE}
7481
peak_dat <- echoannot::granges_overlap(
75-
dat1 = dat,
82+
dat1 = dat,
7683
chrom_col.1 = "CHR",
7784
start_col.1 = "POS",
78-
dat2 = scATACseq_celltype_peaks,
85+
dat2 = scATACseq_celltype_peaks,
7986
chrom_col.2 = "hg38_Chromosome",
8087
start_col.2 = "hg38_Start",
8188
end_col.2 = "hg38_Stop")
82-
ggbio::autoplot(peak_dat,
83-
ggplot2::aes(y=ExcitatoryNeurons, color=Effect))
89+
ggbio::autoplot(peak_dat,
90+
ggplot2::aes(y=ExcitatoryNeurons, color=Effect))
8491
```
8592

8693

87-
# Session Info
94+
# Session Info
8895

89-
<details>
96+
<details>
9097

9198
```{r Session Info}
9299
utils::sessionInfo()
93100
```
94101

95-
</details>
96-
102+
</details>

0 commit comments

Comments
 (0)