Skip to content

Commit

Permalink
Added docstring.
Browse files Browse the repository at this point in the history
  • Loading branch information
MaxBlesch committed May 22, 2021
1 parent 1622657 commit b89d171
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion robupy/get_worst_case.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,11 @@ def calculate_p(v, q, lambda_):

@numba.jit(nopython=True)
def get_worst_case_probs(v, q, beta, is_cost=True):
"""This function returns the worst distribution."""
"""This function returns the worst distribution. Nilim and Gahoui (2005) provide
the algortihm implemented here. However their objective is to minimize costs.
Therefore their algorithm determines the probability maximizing the costs. The
is_cost keyword is therefore specified by default true. If you submit utility (
positive for reward, negatice for costs) this keyword has to be set false."""
checks_get_worst_in(v, q, beta)

# We want to handle two cases explicitly. First we deal with the case that there
Expand Down

0 comments on commit b89d171

Please sign in to comment.