NMRPipe like processing functions for use with the nmrglue.fileio.pipe module.

These functions attempt to mimic NMRPipe’s processing functions but small differences exist between to two implementations. In particular when using this module:

  • hdr=True overrides all values in the calling function.
  • A di flag is not used, rather the di() function should be used to delete the imaginary portion of a spectra.
  • x1, xn and other limits must be expressed in points. A unit conversion object function should be used before calling the processing function to calculate these values.
  • No functions implement the dmx or nodmx flags.

Additional differences from NMRPipe’s functions are documented in the individual processing functions.

The following functions have not been implemented and will raise a NotImplemented exception:

  • ann Fourier Analysis by Neural Net
  • ebs EBS Reconstruction
  • mem Maximum Entropy
  • ml Maximum likelyhood frequency
  • poly Polynomail baseline correction
  • xyz2zyx 3D matrix transpose
  • ztp 3D matrix transpose

This module is imported as nmrglue.pipe_proc and can be called as such.


apod(dic, data[, qName, q1, q2, q3, c, ...]) Generic apodization.
em(dic, data[, lb, c, start, size, inv, ...]) Exponential apodization.
gm(dic, data[, g1, g2, g3, c, start, size, ...]) Lorentz-to-Gauss apodization
gmb(dic, data[, lb, gb, c, start, size, ...]) Modified Gaussian Apodization
jmod(dic, data[, off, j, lb, sin, cos, c, ...]) Exponentially Damped J-Modulation Apodization
sp(dic, data[, off, end, pow, c, start, ...]) Sine bell apodization.
sine(dic, data[, off, end, pow, c, start, ...]) Sine bell apodization.
tm(dic, data[, t1, t2, c, start, size, inv, ...]) Trapezoid apodization.
tri(dic, data[, loc, lHi, rHi, c, start, ...]) Triangular apodization


rs(dic, data[, rs, sw]) Right shift and zero pad.
ls(dic, data[, ls, sw]) Left Shift and Zero Pad
cs(dic, data, dir[, pts, neg, sw]) Circular shift
fsh(dic, data, dir, pts[, sw]) Frequency shift.


ft(dic, data[, auto, real, inv, alt, neg, ...]) Complex Fourier transform.
rft(dic, data[, inv]) Real Fourier transform.
ha(dic, data[, inv]) Hadamard transform.
ht(dic, data[, mode, zf, td, auto]) Hilbert transform.

Standard NMR

di(dic, data) Delete imaginaries
ps(dic, data[, p0, p1, inv, hdr, noup, ht, ...]) Phase shift
tp(dic, data[, hyper, nohyper, auto, nohdr]) Transpose data (2D).
zf(dic, data[, zf, pad, size, mid, inter, ...]) Zero fill


base(dic, data[, nl, nw, first, last]) Linear baseline correction.
cbf(dic, data[, last, reg, slice]) Constant baseline correction.
med(dic, data[, nw, sf, sigma]) Median baseline correction
sol(dic, data[, mode, fl, fs, head]) Solvent filter


add(dic, data[, r, i, c, ri, x1, xn]) Add a constant
dx(dic, data) Derivative by central difference.
ext(dic, data[, x1, xn, y1, yn, round, ...]) Extract a region.
integ(dic, data) Integral by simple sum
mc(dic, data[, mode]) Modules or magnitude calculation.
mir(dic, data[, mode, invl, invr, sw]) Append mirror image.
mult(dic, data[, r, i, c, inv, hdr, x1, xn]) Multiple by a constant.
rev(dic, data[, sw]) Reverse data.
set(dic, data[, r, i, c, x1, xn]) Set data to a constant.
shuf(dic, data[, mode]) Shuffle Utilities
sign(dic, data[, ri, r, i, left, right, ...]) Sign manipulation utilities


coadd(dic, data[, cList, axis, time]) Co-addition of data
coad(dic, data[, cList, axis, time]) Co-addition of data
dev(dic, data) Development function (does nothing)
img(dic, data, filter[, dx, dy, kern, conv, ...]) Image processing utilities
mac(dic, data[, macro, noRd, noWr, all]) Dispatcher similar to the MAC command.
null(dic, data) Null function
qart(dic, data[, a, f, auto]) Scale Quad Artifacts
qmix(dic, data[, ic, oc, cList, time]) Complex mixing of input to outputs
save(dic, data, name[, overwrite]) Save the current vector.
smo(dic, data[, n, center]) Smooth data.
zd(dic, data[, wide, x0, slope, func, g]) Zero diagonal band.

Linear Prediction

lp(dic, data[, pred, x1, xn, ord, mode, ...]) Linear Prediction
lpc(dic, data[, pred, x1, xn, ord, mode, ...]) Linear Prediction
lp2d(dic, data[, xOrd, yOrd, xSize, ySize, ...]) 2D Linear Prediction using LP2D procedure

Not Implemented

ann(dic, data) Fourier Analysis by Neural Net
ebs(dic, data) EBS Reconstruction
mac(dic, data[, macro, noRd, noWr, all]) Dispatcher similar to the MAC command.
mem(dic, data) Maximum Entropy Reconstruction
ml(dic, data) Maximum Likelihood Frequency Map
poly(dic, data) Polynomial Baseline Correction
xyz2zyx(dic, data) 3D Matrix transpose
ztp(dic, data) 3D Matrix Transpose