Fit_Weibull_Exponential
- class reliability.ALT_fitters.Fit_Weibull_Exponential(failures, failure_stress, right_censored=None, right_censored_stress=None, use_level_stress=None, CI=0.95, optimizer=None, show_probability_plot=True, show_life_stress_plot=True, print_results=True)
This function will fit the Weibull-Exponential life-stress model to the data provided. Please see the online documentation for the equations of this model.
This model is most appropriate to model a life-stress relationship with temperature. It is recommended that you ensure your temperature data are in Kelvin.
If you are using this model for the Arrhenius equation, a = Ea/K_B. When results are printed Ea will be provided in eV.
- Parameters:
failures (array, list) – The failure data.
failure_stress (array, list) – The corresponding stresses (such as temperature) at which each failure occurred. This must match the length of failures as each failure is tied to a failure stress.
right_censored (array, list, optional) – The right censored failure times. Optional input.
right_censored_stress (array, list, optional) – The corresponding stresses (such as temperature) at which each right_censored data point was obtained. This must match the length of right_censored as each right_censored value is tied to a right_censored stress. Conditionally optional input. This must be provided if right_censored is provided.
use_level_stress (int, float, optional) – The use level stress at which you want to know the mean life. Optional input.
print_results (bool, optional) – True/False. Default is True. Prints the results to the console.
show_probability_plot (bool, object, optional) – True/False. Default is True. Provides a probability plot of the fitted ALT model. If an axes object is passed it will be used.
show_life_stress_plot (bool, str, object, optional) – If True the life-stress plot will be shown. To hide the life-stress plot use False. To swap the axes and show a stress-life plot use ‘swap’. If an axes handle is passed it will be used. Default is True.
CI (float, optional) – Confidence interval for estimating confidence limits on parameters. Must be between 0 and 1. Default is 0.95 for 95% CI.
optimizer (str, optional) – The optimization algorithm used to find the solution. Must be either ‘TNC’, ‘L-BFGS-B’, ‘nelder-mead’, or ‘powell’. Specifying the optimizer will result in that optimizer being used. To use all of these specify ‘best’ and the best result will be returned. The default behaviour is to try each optimizer in order (‘TNC’, ‘L-BFGS-B’, ‘nelder-mead’, and ‘powell’) and stop once one of the optimizers finds a solution. If the optimizer fails, the initial guess will be returned. For more detail see the documentation.
- Returns:
a (float) – The fitted parameter from the Exponential model
b (float) – The fitted parameter from the Exponential model
beta (float) – The fitted Weibull_2P beta parameter
loglik2 (float) – Log Likelihood*-2 (as used in JMP Pro)
loglik (float) – Log Likelihood (as used in Minitab and Reliasoft)
AICc (float) – Akaike Information Criterion
BIC (float) – Bayesian Information Criterion
a_SE (float) – The standard error (sqrt(variance)) of the parameter
b_SE (float) – The standard error (sqrt(variance)) of the parameter
beta_SE (float) – The standard error (sqrt(variance)) of the parameter
a_upper (float) – The upper CI estimate of the parameter
a_lower (float) – The lower CI estimate of the parameter
b_upper (float) – The upper CI estimate of the parameter
b_lower (float) – The lower CI estimate of the parameter
beta_upper (float) – The upper CI estimate of the parameter
beta_lower (float) – The lower CI estimate of the parameter
results (dataframe) – A dataframe of the results (point estimate, standard error, Lower CI and Upper CI for each parameter)
goodness_of_fit (dataframe) – A dataframe of the goodness of fit criterion (Log-likelihood, AICc, BIC)
change_of_parameters (dataframe) – A dataframe showing the change of the parameters (alpha and beta) at each stress level.
mean_life (float) – The mean life at the use_level_stress (only provided if use_level_stress is provided).
alpha_at_use_stress (float) – The equivalent Weibull alpha parameter at the use level stress (only provided if use_level_stress is provided).
distribution_at_use_stress (object) – The Weibull distribution at the use level stress (only provided if use_level_stress is provided).
probability_plot (object) – The figure object from the probability plot (only provided if show_probability_plot is True).
life_stress_plot (object) – The figure object from the life-stress plot (only provided if show_life_stress_plot is True).
- static LL(params, t_f, t_rc, T_f, T_rc)
- static logR(t, T, a, b, beta)
- static logf(t, T, a, b, beta)