nmrglue.process.proc_lp.lp_model
- nmrglue.process.proc_lp.lp_model(trace, slice=slice(None, None, None), order=8, mode='f', mirror=None, method='svd', full=False)[source]
Use Linear Prediction to model 1D NMR time domain data.
- Parameters
- trace1D ndarray
One dimensional time domain NMR data to model.
- sliceslice object, optional
Slice object which selects the region along the last axis to use in LP equation. The default, slice(None), will use all points.
- orderint
Prediction order, number of LP coefficients calculated.
- mode{‘f’, ‘b’}
Mode to generate LP filter. ‘f’ for forward,’b’ for backward.
- mirror{None, ‘0’, ‘180’}
Mode to form mirror image of data before processing. None will process the data trace as provided (no mirror image). ‘0’ or ‘180’ forms a mirror image of the sliced trace to calculate the LP filter. ‘0’ should be used with data with no delay, ‘180’ with data with an initial half-point delay.
- method{‘svd’, ‘qr’, ‘choleskey’, ‘tls’}
Method to use to calculate the LP filter. Choices are a SVD (‘svd’), QR (‘qr’), or Choleskey (‘choleskey’) decomposition, or Hankel SVD (‘hsvd’).
- fullbool
True to return amplitudes and phases calculated by performing a least squares fitting to the data after LP modeling. False will return only the damping (relaxation) factors and signal frequencies.
- Returns
- damplist
List of damping (relaxation) factors found from LP modeling.
- freqlist
List of signal frequencies found from LP modeling.
- amplist, optional
List of signal amplitudes found by least squares fitting of data after LP modeling, only returned when full parameter is True.
- phaselist, optional.
List of signal phases found by least squares fitting of data after LP modeling, only returned when full parameter is True.
Notes
When backward LP is used the signal roots are reflected before calculating model parameters.