Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
268 changes: 130 additions & 138 deletions examples/survival_analysis/weibull_aft.ipynb

Large diffs are not rendered by default.

12 changes: 6 additions & 6 deletions examples/survival_analysis/weibull_aft.myst.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ jupytext:
format_name: myst
format_version: 0.13
kernelspec:
display_name: pymc
display_name: pymc_env
language: python
name: python3
myst:
Expand All @@ -24,7 +24,7 @@ myst:
:::

```{code-cell} ipython3
import arviz as az
import arviz.preview as az
import numpy as np
import pymc as pm
import pytensor.tensor as pt
Expand All @@ -48,7 +48,7 @@ np.random.seed(RANDOM_SEED)
# Set a seed for reproducibility of posterior results
seed: int = sum(map(ord, "aft_weibull"))
rng: np.random.Generator = np.random.default_rng(seed=seed)
az.style.use("arviz-darkgrid")
az.style.use("arviz-variat")
```

## Dataset
Expand Down Expand Up @@ -125,7 +125,7 @@ with model_1:
```

```{code-cell} ipython3
az.plot_trace(idata_param1, var_names=["alpha", "beta"])
az.plot_trace_dist(idata_param1, var_names=["alpha", "beta"])
```

```{code-cell} ipython3
Expand Down Expand Up @@ -155,7 +155,7 @@ with model_2:
```

```{code-cell} ipython3
az.plot_trace(idata_param2, var_names=["r", "beta"])
az.plot_trace_dist(idata_param2, var_names=["r", "beta"])
```

```{code-cell} ipython3
Expand Down Expand Up @@ -190,7 +190,7 @@ with model_3:
```

```{code-cell} ipython3
az.plot_trace(idata_param3)
az.plot_trace_dist(idata_param3)
```

```{code-cell} ipython3
Expand Down