This file contains 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.optimize | |
import numpy as np | |
import matplotlib.pyplot as plt | |
def F( | |
phi: np.ndarray, | |
uaa: float, ubb: float, uab: float, na: int, nb: int, | |
) -> np.ndarray: | |
""" |
This file contains 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
# Based on https://stackoverflow.com/questions/77470565/probit-and-transforming-z-scores-in-gurobi-price-optimization | |
import numpy as np | |
import pulp | |
import pandas as pd | |
def make_distribution() -> tuple[ | |
np.ndarray, # z scores | |
pd.Series, # probabilities |
OlderNewer