FlexValue: a tool for calculating avoided costs
Project description
This library can be used to calculate the avoided costs, TRC, and PAC.
Try it out for yourself by following our tutorial or with your own data here.
Avoided Cost Data
This uses avoided cost data that is stored in a SQLITE table, which can be downloaded as a SQLite file here (flexvalue_2020.db).
A separate series of pythons scripts were used to generate that sqlite file from a source XLSX file provided by the CEC As of this writing (2021-03-05), the most recent update to the avoided cost data is 2020, which corresponds to the public filename of the SQLite file.
Installation from Source
Docker
docker-compose build
# for running the CLI commands
./flexvalue.sh --help
# for opening the tutorial
docker-compose up jupyter
Local
pip install -e .
# for running cli commands
flexvalue --help
# tutorial (assuming you have jupyter installed
jupyter notebooks/
CLI Commands
Before calculating any results, you will need to download the avoided cost data for a given year. .. code-block:: shell
flexvalue download-avoided-costs-data-db –year 2020
To get an example set of flexvalue results, run the following commands in order.
flexvalue generate-example-inputs
flexvalue get-results --user-inputs-filepath ../test_data/example_user_inputs_deer.csv --report-filepath reports/example_report_deer.html
flexvalue get-results --user-inputs-filepath ../test_data/example_user_inputs_metered.csv --metered-load-shape-filepath ../test_data/example_metered_load_shape.csv --report-filepath reports/example_report_metered.html
To help generate your user input file, use the following command to see what utilities, climate zones, and deer load shapes are available.
flexvalue valid-utility-climate-zone-combos
flexvalue valid-deer-load-shapes
License
This project is licensed under Apache 2.0.
Other resources
CONTRIBUTING: how to contribute to the project.
CODE_OF_CONDUCT: Code of conduct for contributors.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for flexvalue-0.0.1-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3f0d1496b737d8beaa038de11136111baebb2b709a96a9475b54ab0935d3207f |
|
MD5 | 135b602a39ac85ee34efd3c125e8ea2b |
|
BLAKE2b-256 | 700d9dbe038bddfa9b6bf17e2e107a438bf6303f843bc4beab921cd083f09bac |