From 224e30290aec20a942832585a425afeeae5ec58c Mon Sep 17 00:00:00 2001
From: Fumito Hamamura
Date: Wed, 3 May 2023 12:55:56 +0900
Subject: [PATCH] DOC: Update docs for release v0.8.1
---
.../libraries/savings/savings_example4.ipynb | 2 +-
makedocs/source/archive.rst | 1 +
makedocs/source/libraries/savings/index.rst | 4 ++-
.../libraries/savings/savings_example4.nblink | 3 ++
makedocs/source/releases/relnotes_v0.8.1.rst | 30 +++++++++++++++++++
makedocs/source/updates.rst | 5 ++++
makedocs/source/whatsnew.rst | 1 +
7 files changed, 44 insertions(+), 2 deletions(-)
create mode 100644 makedocs/source/libraries/savings/savings_example4.nblink
create mode 100644 makedocs/source/releases/relnotes_v0.8.1.rst
diff --git a/lifelib/libraries/savings/savings_example4.ipynb b/lifelib/libraries/savings/savings_example4.ipynb
index 5450bf2..160c6b6 100644
--- a/lifelib/libraries/savings/savings_example4.ipynb
+++ b/lifelib/libraries/savings/savings_example4.ipynb
@@ -653,7 +653,7 @@
"id": "3a435fef",
"metadata": {},
"source": [
- "The output tells that `surr_charge_rate(t)` is consuming time the most, which is more than 30% of the total run time. Its fomula looks like below.\n",
+ "The output tells that `surr_charge_rate(t)` is consuming time the most, which is more than 40% of the total run time. Its fomula looks like below.\n",
"\n",
"`surr_charge_rate(t)` represents the surrener charge rates to be applied at time `t`. The surrender charge rates are defined by rate ID (such as `type_1`) and duration, and stored in `surr_charge_table` as a DataFrame. "
]
diff --git a/makedocs/source/archive.rst b/makedocs/source/archive.rst
index 9aace3c..f617840 100644
--- a/makedocs/source/archive.rst
+++ b/makedocs/source/archive.rst
@@ -11,6 +11,7 @@ Past Documents
.. raw:: html
+ - lifelib v0.8.0
- lifelib v0.7.0
- lifelib v0.6.0
- lifelib v0.5.0
diff --git a/makedocs/source/libraries/savings/index.rst b/makedocs/source/libraries/savings/index.rst
index c3ea30b..97b0435 100644
--- a/makedocs/source/libraries/savings/index.rst
+++ b/makedocs/source/libraries/savings/index.rst
@@ -102,7 +102,7 @@ Examples
savings_example1
savings_example2
savings_example3
-
+ savings_example4
Library Contents
@@ -119,9 +119,11 @@ Library Contents
cash_value_sample.xlsx An Excel file that reproduces the results of a selected model point. The file also shows the derivation of the sample mortality rates.
CashValue_ME_EX1 The example model for *savings_example1.ipynb*
CashValue_ME_EX2 The example model for *savings_example2.ipynb*
+ CashValue_ME_EX4 The example model for *savings_example4.ipynb*
savings_example1.ipynb Jupyter notebook :doc:`savings_example1`
savings_example2.ipynb Jupyter notebook :doc:`savings_example2`
savings_example3.ipynb Jupyter notebook :doc:`savings_example3`
+ savings_example4.ipynb Jupyter notebook :doc:`savings_example4`
generate_100K_model_points.ipynb Jupyter notebook used for generating the large model point data for :doc:`/libraries/savings/savings_example3`.
plot_ex1_av_paths.py Python script for :doc:`/generated_examples/savings/plot_ex1_av_paths`
plot_ex1_rand.py Python script for :doc:`/generated_examples/savings/plot_ex1_rand`
diff --git a/makedocs/source/libraries/savings/savings_example4.nblink b/makedocs/source/libraries/savings/savings_example4.nblink
new file mode 100644
index 0000000..a0dcbe7
--- /dev/null
+++ b/makedocs/source/libraries/savings/savings_example4.nblink
@@ -0,0 +1,3 @@
+{
+ "path": "../../../../lifelib/libraries/savings/savings_example4.ipynb"
+}
\ No newline at end of file
diff --git a/makedocs/source/releases/relnotes_v0.8.1.rst b/makedocs/source/releases/relnotes_v0.8.1.rst
new file mode 100644
index 0000000..12b7135
--- /dev/null
+++ b/makedocs/source/releases/relnotes_v0.8.1.rst
@@ -0,0 +1,30 @@
+.. currentmodule:: lifelib.libraries
+
+.. _relnotes_v0.8.1:
+
+==================================
+lifelib v0.8.1 (3 May 2023)
+==================================
+
+This release adds a new example in :mod:`~savings`.
+
+To update lifelib, run the following command::
+
+ >>> pip install lifelib --upgrade
+
+If you're using Anaconda, use the ``conda`` command instead::
+
+ >>> conda update lifelib
+
+
+New Example
+===============
+
+This release adds a new example, :doc:`/libraries/savings/savings_example4` in :mod:`~savings`.
+The example shows how to profile and optimize a model using ``CashValue_ME_EX1`` as an example.
+The optimization approach involves replacing pandas DataFrames and Series with numpy arrays.
+The optimized model used in the example is included in :mod:`~savings` as ``CashValue_ME_EX4``.
+The example is based on recommendation given by `alexeybaran `_
+
+
+
diff --git a/makedocs/source/updates.rst b/makedocs/source/updates.rst
index 9d7937f..6a8384b 100644
--- a/makedocs/source/updates.rst
+++ b/makedocs/source/updates.rst
@@ -14,6 +14,11 @@ Updates
Follow lifelib on LinkedIn
for more frequent updates.
+* *3 May 2023:*
+ lifelib v0.8.1 is released. A new example, :doc:`/libraries/savings/savings_example4` is available in :mod:`~savings`.
+ See :ref:`Release Notes` for details.
+
+
* *19 Nov 2022:*
lifelib v0.8.0 is released. New library :mod:`~economic_curves` is available.
See :ref:`Release Notes` for details.
diff --git a/makedocs/source/whatsnew.rst b/makedocs/source/whatsnew.rst
index 1663487..ff01b2f 100644
--- a/makedocs/source/whatsnew.rst
+++ b/makedocs/source/whatsnew.rst
@@ -33,6 +33,7 @@ Documentation for released versions of lifelib is available under
.. toctree::
:maxdepth: 2
+ releases/relnotes_v0.8.1
releases/relnotes_v0.8.0
releases/relnotes_v0.7.0
releases/relnotes_v0.6.0