I am a bit new to pymc3 and probabilistic programming in general. I have a dataset on widgets. The widgets get inspected at a certain frequency and when that happens, the machine that produces widgets is down. We think that the widgets are sampled way too often. For example, if the natural defect rate is 1 in 10 on average, the widgets are getting inspected at 1 in 5.
I want to prove my hypothesis and do so, I am considering pymc3. My thought is
- Build a pymc3 model with uniformative prior for the defect rate (flat normal)
- Calculate the likelihood for defect rate using the daily data
- The posterior will show the defect rate distribution.
- We will set the inspection frequency such that the chance of seeing a defect rate higher than the frequency will be <=5%
I have daily data for each widget inspection and it’s outcome. Can anyone verify this thought process? Specifically, I am not sure about how I will populate the observed parameter in the likelihood. I think I will pass in the daily defect rate to it, but not sure whether it will be daily or weekly or some other frequency. Can anyone guide me here?