mescla.prep.missing.impute_below_detection

mescla.prep.missing.impute_below_detection(table, factor=0.5)[source]

Replace non-detects by factor times their detection limit.

Warning

This is the conventional shortcut and it is biasing: it invents a precision the measurement does not have, and the bias is systematic rather than random. It is provided because you will meet datasets already treated this way and will want to reproduce them.

Prefer leaving the values censored and letting mescla.mixing.lsq.mixing_ratios() treat them as the one-sided information they are.

Parameters:
  • factor (float, default 0.5) – The usual choices are 0.5 (half the limit) or 1/sqrt(2).

  • table (Any)

Return type:

ChemTable