Skip to content

Commit f6549fc

Browse files
committed
chore: change data type to Literal in PortfolioDCF.find_the_largest_withdrawals_size.goal
1 parent 9a117a4 commit f6549fc

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

okama/portfolio.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
from random import randint
2-
from typing import Optional, List, Dict, Union, Tuple
2+
from typing import Optional, List, Dict, Union, Tuple, Literal
33

44
import numpy as np
55
import pandas as pd
@@ -3002,7 +3002,7 @@ def monte_carlo_survival_period(self, threshold: float = 0) -> pd.Series:
30023002

30033003
def find_the_largest_withdrawals_size(
30043004
self,
3005-
goal: str,
3005+
goal: Literal['maintain_balance_pv', 'maintain_balance_fv', 'survival_period'],
30063006
withdrawals_range: Tuple[float, float] = (0, 1),
30073007
target_survival_period: int = 25,
30083008
percentile: int = 20,

0 commit comments

Comments
 (0)