Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def LL(params, T_f, T_rc): # log likelihood function (2 parameter Gamma)
LL_f = 0
LL_rc = 0
LL_f += Fit_Gamma_2P.logf(T_f, params[0], params[1]).sum() # failure times
LL_rc += Fit_Gamma_2P.logR(T_rc, params[0], params[1]).sum() # right censored times
return -(LL_f + LL_rc)
def LL_fb(params, T_f, T_rc, force_beta): # log likelihood function (2 parameter Gamma) FORCED BETA
LL_f = 0
LL_rc = 0
LL_f += Fit_Gamma_2P.logf(T_f, params[0], force_beta).sum() # failure times
LL_rc += Fit_Gamma_2P.logR(T_rc, params[0], force_beta).sum() # right censored times
return -(LL_f + LL_rc)