Skip to content

Commit 6529075

Browse files
authored
add example from pymc_examples (#7)
* add example fron pymc_examples * add example fron pymc_examples * use wget instead of intersphinx * avoid duplicating files
1 parent 3ab6cd9 commit 6529075

File tree

2 files changed

+16
-3
lines changed

2 files changed

+16
-3
lines changed

docs/conf.py

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,19 @@
4848
"nbsphinx",
4949
]
5050

51+
external_docs = ["examples/BART_introduction.ipynb", "examples/references.bib"]
52+
for doc in external_docs:
53+
if os.path.exists(doc):
54+
os.remove(doc)
55+
56+
os.system("wget https://raw.githubusercontent.com/pymc-devs/pymc-examples/main/examples/case_studies/BART_introduction.ipynb -P examples")
57+
os.system("wget https://raw.githubusercontent.com/pymc-devs/pymc-examples/main/examples/references.bib -P examples")
58+
59+
# bibtex config
60+
bibtex_bibfiles = ["references.bib"]
61+
bibtex_default_style = "unsrt"
62+
bibtex_reference_style = "author_year"
63+
5164
nbsphinx_execute = "never"
5265

5366
# Add any paths that contain templates here, relative to this directory.
@@ -56,8 +69,7 @@
5669
# The suffix(es) of source filenames.
5770
# You can specify multiple suffix as a list of string:
5871
#
59-
# source_suffix = ['.rst', '.md']
60-
source_suffix = ".rst"
72+
source_suffix = ['.rst', '.md']
6173

6274
# The master toctree document.
6375
master_doc = "index"

docs/index.rst

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,8 +80,9 @@ Contents
8080
========
8181

8282
.. toctree::
83-
:maxdepth: 4
83+
:maxdepth: 2
8484

85+
examples/BART_introduction
8586
api_reference
8687

8788
Indices

0 commit comments

Comments
 (0)