Created
September 28, 2023 22:17
-
-
Save DiogoRibeiro7/2311c8d90f18d3516eb5ef107842bb51 to your computer and use it in GitHub Desktop.
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
def expected_utility_logarithmic(simulations, a=1): | |
utilities = a * np.log(simulations) | |
return np.mean(utilities) | |
# Evaluate the expected utility of the simulations | |
expected_utility = expected_utility_logarithmic(simulations) | |
print(f'Expected Utility: {expected_utility}') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment