summaryrefslogtreecommitdiff
path: root/demo
diff options
context:
space:
mode:
Diffstat (limited to 'demo')
-rwxr-xr-xdemo47
1 files changed, 0 insertions, 47 deletions
diff --git a/demo b/demo
deleted file mode 100755
index bb9cb98..0000000
--- a/demo
+++ /dev/null
@@ -1,47 +0,0 @@
-#!/usr/bin/python3
-
-
-import argparse
-
-from datetime import datetime
-from decimal import Decimal
-
-from finance.flow import Flow, simulate
-from finance.visualize import display
-
-
-DESCRIPTION = "Demo application plotting financial data with finance-py"
-
-
-def main() -> None:
- argparse.ArgumentParser(description=DESCRIPTION).parse_args()
-
- measured = [
- (datetime(2024, 1, 1), Decimal(105.0)),
- (datetime(2024, 2, 1), Decimal(207.0)),
- (datetime(2024, 3, 1), Decimal(334.0)),
- ]
-
- flows = (
- Flow(amount=Decimal(100.0), since=None, until=None),
- Flow(
- amount=Decimal(200.0),
- since=datetime(2026, 1, 1),
- until=datetime(2027, 1, 1),
- ),
- )
-
- simulated = simulate(
- start=datetime(2024, 1, 1),
- end=datetime(2030, 1, 1),
- flows=flows,
- )
-
- display(
- simulated=simulated,
- measured=measured,
- )
-
-
-if __name__ == "__main__":
- main()