emzed.align.rt_align module

emzed.align.rt_align.rt_align(tables, reference_table=None, destination=None, reset_integration=False, n_peaks=-1, max_rt_difference=100, max_mz_difference=0.3, max_mz_difference_pair_finder=0.5, model='b_spline', **model_parameters)[source]

aligns feature tables in respect to retention times. the algorithm returns new tables with aligned data.

Parameters:
  • reference_table – extra reference table, if None the table with most features among tables is taken.

  • destination – target folder for quality plots. If this value is None no plots will be created.

  • reset_integration – sets integration related column names to None if present. Else the alignment will fail for already integrated tables.

  • n_peaks – max number of peaks matched by superimposer, -1 means: all peaks, can be float between 0 and 1 to refer to fraction of peaks in reference table.

  • max_rt_difference – max allowed difference in rt values for searching matching features.

  • max_mz_difference – max allowed difference in mz values for super imposer.

  • max_mz_difference_pair_finder – max allowed difference in mz values for pair finding.

  • model – can be “b_spline” or “lowess”

  • model_parameters

    key word parameters depending on provided value for ‘model’. For ‘b_spline’ the user can set

    • num_nodes: number of break points of fitted spline.

      default:5, more points result in splines with higher variation.

    For ‘lowess’ the parameters are:

    • span: value between 0 and 1, larger values lead to more smoothing.

      default is 2/3.

    • interpolation_type: either “cspline” or “linear”

Returns:

aligned peak tables.