R/plot-failure-modes.R
separate_failure_modes.RdFor a data.frame containing a column with (some) multiple failure modes,
this function expands the data.frame by repeating each row with multiple
failure modes so that each row contains only a single failure mode.
separate_failure_modes(data, failure_mode, sep = "[/, ]+")When multiple failure modes are reported, they are commonly reported in the format "LGM/GIT" or "LGM,GIT". This function will separate these multiple failure modes into multiple rows.
This can be useful when counting the number of coupons exhibited each failure mode.