MCF_parametric(data, CI=0.95, plot_CI=True, print_results=True, show_plot=True, **kwargs)¶
The Mean Cumulative Function (MCF) is a cumulative history function that shows the cumulative number of recurrences of an event, such as repairs over time. In the context of repairs over time, the value of the MCF can be thought of as the average number of repairs that each system will have undergone after a certain time. It is only applicable to repairable systems and assumes that each event (repair) is identical. In the case of the fitted paramertic MCF, it is assumed that each system’s MCF is identical.
The shape (beta parameter) of the MCF is a key indicator that shows whether the systems are improving (beta<1), worsening (beta>1), or staying the same (beta=1) over time. If the MCF is concave down (appearing to level out) then the system is improving. A straight line (constant increase) indicates it is staying the same. Concave up (getting steeper) shows the system is worsening as repairs are required more frequently as time progresses.
- data (list) – The repair times for each system. Format this as a list of lists. eg. data=[[4,7,9],[3,8,12]] would be the data for 2 systems. The largest time for each system is assumed to be the retirement time and is treated as a right censored value. If the system was retired immediately after the last repair then you must include a repeated value at the end as this will be used to indicate a right censored value. eg. A system that had repairs at 4, 7, and 9 then was retired after the last repair would be entered as data = [4,7,9,9] since the last value is treated as a right censored value. If you only have data from 1 system you may enter the data in a single list as data = [3,7,12] and it will be nested within another list automatically.
- print_results (bool, optional) – Prints the table of MCF results (state, time, MCF_lower, MCF, MCF_upper, variance). Default = True.
- CI (float, optional) – Confidence interval. Must be between 0 and 1. Default = 0.95 for 95% CI (one sided).
- show_plot (bool, optional) – If True the plot will be shown. Default = True. Use plt.show() to show it.
- plot_CI (bool, optional) – If True, the plot will include the confidence intervals. Default = True. Set as False to remove the confidence intervals from the plot.
- kwargs – Plotting keywords that are passed directly to matplotlib (e.g. color, label, linestyle).
- times (array) – This is the times (x values) from the scatter plot. This value is calculated using MCF_nonparametric.
- MCF (array) – This is the MCF (y values) from the scatter plot. This value is calculated using MCF_nonparametric.
- alpha (float) – The calculated alpha parameter from MCF = (t/alpha)^beta
- beta (float) – The calculated beta parameter from MCF = (t/alpha)^beta
- alpha_SE (float) – The standard error in the alpha parameter
- beta_SE (float) – The standard error in the beta parameter
- cov_alpha_beta (float) – The covariance between the parameters
- alpha_upper (float) – The upper CI estimate of the parameter
- alpha_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)
This example is taken from Reliasoft’s example (available at http://reliawiki.org/index.php/Recurrent_Event_Data_Analysis). The failure times and retirement times (retirement time is indicated by +) of 5 systems are:
System Times 1 5,10,15,17+ 2 6,13,17,19+ 3 12,20,25,26+ 4 13,15,24+ 5 16,22,25,28+
from reliability.Repairable_systems import MCF_parametric times = [[5, 10, 15, 17], [6, 13, 17, 19], [12, 20, 25, 26], [13, 15, 24], [16, 22, 25, 28]] MCF_parametric(data=times)