Skip to content

Commit

Permalink
add notes about interactive plots on website
Browse files Browse the repository at this point in the history
  • Loading branch information
mmcky committed May 3, 2021
1 parent f174864 commit d08256a
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 9 deletions.
24 changes: 21 additions & 3 deletions lectures/black_litterman.md
Original file line number Diff line number Diff line change
Expand Up @@ -382,10 +382,10 @@ customer's portfolio will involve big short-long positions.

```{note}
To Generate an Interactive Plot you can use the ipywidget
decorator `interact`.
decorator `interact`. Interactive plotting requires the [ipywidgets](https://github.com/jupyter-widgets/ipywidgets) module to be installed and enabled.
This doesn't currently display on the website. Working
to support rich content such as ipywidgets as HTML javascript objects.
The following `code-cell` doesn't currently display on the website. We are working
to support rich content such as `ipywidgets` as HTML javascript objects.
https://github.com/QuantEcon/lecture-python-advanced.myst/issues/28
Expand Down Expand Up @@ -616,6 +616,15 @@ $\bar d_2$ on the RHS of the constraint, by varying
$\bar d_2$ (or $\lambda$ ), we can trace out the whole curve
as the figure below illustrates.

```{note}
The following `code-cell` doesn't currently display on the website. We are working
to support rich content such as `ipywidgets` as HTML javascript objects.
https://github.com/QuantEcon/lecture-python-advanced.myst/issues/28
However you can use the [binder link](https://mybinder.org/v2/gh/QuantEcon/lecture-python-advanced.notebooks/master?urlpath=tree/black_litterman.ipynb) to launch this notebook on mybinder
```

```{code-cell} python3
:tags: ["remove-output"]
np.random.seed(1987102)
Expand Down Expand Up @@ -702,6 +711,15 @@ This leads to the
following figure, on which the curve connecting $\hat \mu$
and $\mu_{BL}$ are bending

```{note}
The following `code-cell` doesn't currently display on the website. We are working
to support rich content such as `ipywidgets` as HTML javascript objects.
https://github.com/QuantEcon/lecture-python-advanced.myst/issues/28
However you can use the [binder link](https://mybinder.org/v2/gh/QuantEcon/lecture-python-advanced.notebooks/master?urlpath=tree/black_litterman.ipynb) to launch this notebook on mybinder
```

```{code-cell} python3
:tags: ["remove-output"]
λ_grid = np.linspace(.001, 20000, 1000)
Expand Down
10 changes: 4 additions & 6 deletions lectures/matsuyama.md
Original file line number Diff line number Diff line change
Expand Up @@ -787,9 +787,7 @@ plt.show()

Additionally, instead of just seeing 4 plots at once, we might want to
manually be able to change $\rho$ and see how it affects the plot
in real-time. Below we use an interactive plot to do this.

Note, interactive plotting requires the [ipywidgets](https://github.com/jupyter-widgets/ipywidgets) module to be installed and enabled.
in real-time. Below we will turn the following figure into an interactive plot.

```{code-cell} python3
#Setup Parameters
Expand All @@ -815,14 +813,14 @@ plt.show()

```{note}
To Generate an Interactive Plot you can use the ipywidget
decorator `interact`.
decorator `interact`. Interactive plotting requires the [ipywidgets](https://github.com/jupyter-widgets/ipywidgets) module to be installed and enabled.
This doesn't currently display on the website. Working
This doesn't currently display on the website. We are working
to support rich content such as ipywidgets as HTML javascript objects.
https://github.com/QuantEcon/lecture-python-advanced.myst/issues/28
However you can use the [binder link](https://mybinder.org/v2/gh/QuantEcon/lecture-python-advanced.notebooks/master?urlpath=tree/matsuyama.ipynb) to launch this notebook on mybinder
However you can use the [binder link](https://mybinder.org/v2/gh/QuantEcon/lecture-python-advanced.notebooks/master?urlpath=tree/matsuyama.ipynb) to launch this notebook on mybinder.
```

```{code-cell} python3
Expand Down

1 comment on commit d08256a

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.