Skip to content

Commit

Permalink
✨ Add tutorials to the docs
Browse files Browse the repository at this point in the history
- for now locally
- tutorials will be executed on build (can be changed)
  • Loading branch information
Henry committed Nov 3, 2023
1 parent 7f568ed commit 1097619
Show file tree
Hide file tree
Showing 6 changed files with 31 additions and 9 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ a paper on fatty liver disease.

## Installation

Install using pip from [PyPi](https://pypi.org/project/njab) version
Install using pip from [PyPi](https://pypi.org/project/njab) version.

```
pip install njab
Expand Down
8 changes: 7 additions & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,16 @@
'sphinx.ext.autodoc',
'sphinx.ext.autodoc.typehints',
'sphinx.ext.viewcode',
'myst_parser',
'myst_nb',
'sphinx.ext.napoleon',
]

# https://myst-nb.readthedocs.io/en/latest/computation/execute.html
nb_execution_mode = "auto"

myst_enable_extensions = ["dollarmath", "amsmath"]


# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']

Expand Down
20 changes: 18 additions & 2 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,27 @@ functionality used two papers.
.. include:: ../README.md
:parser: myst_parser.sphinx_
:start-line: 1
.. :end-line: 22


Try it yourself
---------------

The tutorial showcasing most of the basic functionality can be found on the following
pages

.. toctree::
:maxdepth: 2
:caption: Tutorials

tutorial/explorative_analysis
tutorial/log_reg

Python Package reference
------------------------

.. toctree::
:maxdepth: 2
:caption: Python Package Reference:
:

reference/modules

Expand Down
4 changes: 2 additions & 2 deletions docs/tutorial/log_reg.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -975,7 +975,7 @@
"id": "53800467",
"metadata": {},
"source": [
"# Performance evaluations"
"## Performance evaluations"
]
},
{
Expand Down Expand Up @@ -1065,7 +1065,7 @@
"id": "a1326dcd",
"metadata": {},
"source": [
"# Multiplicative decompositon"
"## Multiplicative decompositon"
]
},
{
Expand Down
4 changes: 2 additions & 2 deletions docs/tutorial/log_reg.py
Original file line number Diff line number Diff line change
Expand Up @@ -522,7 +522,7 @@
# pred_bins_val

# %% [markdown]
# # Performance evaluations
# ## Performance evaluations

# %%
prc = pd.DataFrame(results_model.train.prc,
Expand Down Expand Up @@ -567,7 +567,7 @@
_

# %% [markdown]
# # Multiplicative decompositon
# ## Multiplicative decompositon

# %%

Expand Down
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ install_requires =
docs =
sphinx
sphinx-book-theme
myst-parser
myst-nb

[options.packages.find]
where = src
Expand Down

0 comments on commit 1097619

Please sign in to comment.