All problems
Uniform MLE Upper Bound
Problem
For a uniform distribution on [0, theta], the maximum likelihood estimate of theta is the sample maximum.
Given the sample values, return the MLE.
Hint
The likelihood increases with theta until the largest observation.
Test cases
case 1
in: [[1,5,3]]
expected: 5
case 2
in: [[0.5]]
expected: 0.5
case 3
in: [[2,2]]
expected: 2
Starter codePython
def uniform_mle_upper_bound(values):
# Your code here
pass3 test cases · run your code against them in the editor