/
Snakefile
33 lines (32 loc) · 1.19 KB
/
Snakefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
rule manuscript:
input:
"latex/figures/fig2-required-sample-size-comparison.pdf",
"latex/figures/fig3-pos-prime-composition.pdf",
"latex/figures/fig4-power-distribution-ep-approach.pdf",
"latex/figures/fig5-power-distribution-quantile-approach.pdf",
"latex/figures/fig6-clinical-trial-example.pdf",
"latex/figures/fig7-matched-reward.pdf"
output:
"latex/main.pdf"
shell:
"""
set -ex
Rscript -e "setwd('latex'); tinytex::latexmk('main.tex', bib_engine = 'biber')"
"""
rule figures:
output:
"latex/figures/fig2-required-sample-size-comparison.pdf",
"latex/figures/fig3-pos-prime-composition.pdf",
"latex/figures/fig4-power-distribution-ep-approach.pdf",
"latex/figures/fig5-power-distribution-quantile-approach.pdf",
"latex/figures/fig6-clinical-trial-example.pdf",
"latex/figures/fig7-matched-reward.pdf"
shell:
"""
set -ex
jupyter nbconvert \
--to notebook \
--execute --ExecutePreprocessor.timeout=600 \
notebooks/figures-for-manuscript.ipynb
mv notebooks/fig*.pdf latex/figures
"""