The whatif package helps you build business analysis oriented models in Python that you might normally build in Excel. Specifically, whatif includes functions that are similar to Excel's Data Tables and Goal Seek for doing sensitivity analysis and "backsolving" (e.g. finding a breakeven point). It also includes functions for facilitating Monte-Carlo simulation using these models.
Related blog posts
The whatif package is new and quite small. It contains:
- a base
Modelclass that can be subclassed to create new models - Functions for doing data tables (
data_table) and goal seek (goal_seek) on a models - Functions for doing Monte-Carlo simulation with a model (
simulate)
Clone the whatif project from GitHub:
.. code::
git clone https://github.com/misken/whatif.git
and then you can install it locally by running the following from the project directory.
.. code::
cd whatif
pip install .
See the Getting started with whatif page in the docs.
The project is licensed under the MIT license.