All problems
Bonferroni Threshold
Problem
Return the Bonferroni-corrected significance threshold alpha/m for m tests. Return 0.0 when m <= 0.
Hint
Divide the family-wise level by the number of tests.
Test cases
case 1
in: [0.05,10]
expected: 0.005
case 2
in: [0.01,5]
expected: 0.002
case 3
in: [0.05,1]
expected: 0.05
case 4
in: [0.05,0]
expected: 0
case 5
in: [0.1,4]
expected: 0.025
Starter codePython
def bonferroni_threshold(alpha, m):
# Your code here
pass5 test cases · run your code against them in the editor