This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import random | |
doors = ['Goat', 'Car', 'Goat'] | |
n = 1000 | |
win = 0 | |
lose = 0 | |
for _ in range(n): | |
#-------------------------# |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import scipy.stats as st | |
import numpy as np | |
def black_scholes_pricing_model( | |
option_type: str, | |
s: float, | |
k: float, | |
r: float, | |
v: float, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def dollar_averaging(df, trade_date, trade_amount, f_or_b = 'f'): | |
''' | |
Input: | |
1. df (dataframe) | |
---> Datetime object should be set as index | |
2. trade_date (int) | |
---> determine which date to invest |
NewerOlder