Home Archives Search Feed Football Squares How To Use


MLB (Braves @ Twins): Will there be a HOME RUN hit during INNINGS 1-2?


8:10 PM
Yes: 1+ HR hit during Innings 1-2
No:  0 HR hit during Innings 1-2


Inputs To Solve

HOME RUNS by team 2019

##### User Estimates #####
ATL_HRperGame = 177/114
MIN_HRperGame = 219/112

expected_total_HRs = ATL_HRperGame + MIN_HRperGame

print("Use %s + %s = %s as total expected HRs to be hit for the game." 
      % (round(ATL_HRperGame,3),round(MIN_HRperGame,3),round(expected_total_HRs,3)))

Use 1.553 + 1.955 = 3.508 as total expected HRs to be hit for the game.    

## Inputs Defined in the Problem
period_of_innings = 2
HRs = 0

Method to Solve

lambda_ = expected_total_HRs * period_of_innings / 9
print("lambda = the total expected HRs hit by both teams over two innings")
print("lambda = %s * %s / %s" % (round(expected_total_HRs,3),period_of_innings,9))
print("lambda ~ %s" % (round(lambda_,3)))

lambda = the total expected HRs hit by both teams over two innings
lambda = 3.508 * 2 / 9
lambda ~ 0.78    

import math

p_zero = math.exp(-lambda_)*(lambda_**HRs)/(math.factorial(HRs))

print("The probability of k events occurring in an Poisson interval = e^(-lambda) * (lambda^k)/k!")
print('where k = 0')
print(' ')
print("p_zero = e^(-%s)*(%s^%s)/%s!" % (round(lambda_,3),round(lambda_,3),HRs,HRs))

The probability of k events occurring in an Poisson interval = e^(-lambda) * (lambda^k)/k!
where k = 0

p_zero = e^(-0.78)*(0.78^0)/0!    


Solution

print("The probability of zero HOME RUNS being hit during Innings 1-2 is ~ %s" % (round(p_zero,3)))

The probability of zero HOME RUNS being hit during Innings 1-2 is ~ 0.459

Posted on 8/6/2019






← Next post    ·    Previous post →