mirror of
https://github.com/DeaDvey/mathgenerator.git
synced 2025-11-28 06:25:23 +01:00
conditional probability fix
This commit is contained in:
@@ -16,10 +16,12 @@ def conditionalProbFunc():
|
||||
|
||||
problem = "Someone tested positive for a nasty disease which only {0:.2f}% of population have. " \
|
||||
"Test sensitivity (true positive) is equal to SN= {1:.2f}% whereas test specificity (true negative) SP= {2:.2f}%. " \
|
||||
"What is the probability that this guy really has that disease?".format(P_disease, true_positive, true_negative)
|
||||
"What is the probability that this guy really has that disease?".format(
|
||||
P_disease, true_positive, true_negative)
|
||||
answer = str(round(BayesFormula(P_disease, true_positive, true_negative), 2)) + "%"
|
||||
|
||||
return problem, answer
|
||||
|
||||
|
||||
conditionalProb = Generator("Conditional Probability", 101, "P(A|+)=", "c", conditionalProbFunc)
|
||||
conditional_probability = Generator("Conditional Probability",
|
||||
105, "P(A|+)=", "c", conditionalProbFunc)
|
||||
Reference in New Issue
Block a user