
FR_to_FNRN¶
-
class
reliability.Convert_data.
FR_to_FNRN
(failures, right_censored=None)¶ Converts data from FR format to FNRN format
Parameters: - failures (array, list) – The failure times
- right censored (array, list, optional) – The right censored times
Returns: - failures (array) – The failure times
- num_failures (array) – The number of failures are each failure time
- right_censored (array) – The right censored times
- num_right_censored (array) – The number of values at each right_censored time
Notes
Example usage:
FNRN = FR_to_FNRN(failures=[1,1,2,2,3], right_censored=[9,9,9,9,8,8,7]) print(FNRN.failures) >>> [1 2 3] print(FNRN.num_failures) >>> [2 2 1] print(FNRN.right_censored) >>> [7 8 9] print(FNRN.num_right_censored) >>> [1 2 4] FNRN.print() >>> Data (FNRN format) failures number of failures right censored number of right censored 1 2 7 1 2 2 8 2 3 1 9 4
-
print
()¶ This will print a dataframe of the data in FNRN format to the console
-
write_to_xlsx
(path, **kwargs)¶ This will export the data in FNRN format to an xlsx file at the specified path.
Parameters: - path (str) – The file path of the xlsx file to be written
- kwargs – Keyword arguments passed directly to pandas