nmrglue.proc_base
A collection of NMR spectral processing functions which operate on the last dimension (1) of 2D arrays. These functions are wrapped by other processing modules but can also be used directly. All parameter are assumed to be in units of points unless otherwise noted.
This module is imported as nmrglue.proc_base and can be called as such.
Apodization
|
Exponential apodization |
|
Lorentz-to-Gauss apodization |
|
Modified gaussian apodization |
|
Exponentially damped J-modulation apodization |
|
Shifted sine-bell apodization |
|
Shifted sine-bell apodization |
|
Trapezoid Apodization |
|
Triangle apodization. |
Shifts
|
Right shift and zero fill. |
|
Left shift and fill with zero |
|
Circular shift |
|
Roll axis |
|
Frequency shift by Fourier transform. |
Transforms
|
Real Fourier transform. |
|
Inverse real fourier transform |
|
Fourier transform, NMR ordering of results. |
|
Fourier transform, total power preserved, NMR ordering of results |
|
Fourier transform with positive exponential, NMR ordering of results |
|
Inverse fourier transform, NMR ordering of results. |
|
Inverse fourier transform, total power preserved, NMR ordering of results |
|
Inverse fourier transform with positive exponential, NMR ordered results. |
|
Hadamard Transform |
|
Hilbert transform. |
Standard NMR
|
Delete imaginary from data |
|
Linear phase correction |
|
Exponential Phase Correction |
|
Transpose data. |
|
Transpose data. |
|
Transpose data. |
|
Hypercomplex tranpose. |
|
Zero fill between points. |
|
Zero fill by padding with zeros. |
|
Zero fill by padding with zeros. |
|
Zero fill by doubling original data size once or multiple times. |
|
Zero fill to given size. |
|
Zero fill to next largest power of two. |
Basic Utilities
|
Add constant. |
|
Add real and imaginary components. |
|
Derivative by central difference |
|
Extract region. |
|
Extract the left half of spectrum. |
|
Extract the right half of the spectrum. |
|
Extract the middle of the spectrum. |
|
Integrate by cumulative sum. |
|
Modulus calculation. |
|
Modulus calculation. |
|
Append a mirror image of the data on the left. |
|
Append a mirror image of the data on the right. |
|
Append a mirror image of the data in the center. |
|
Append a mirror image of the data in the center with a one point shift amd negate appended imaginary data. |
|
Multiply by a constant. |
|
Reverse data. |
|
Set to a constant. |
|
Set real and imaginary portions of data to a constant. |
|
Set real component of data to a constant. |
|
Set imaginary portion of data to a constant. |
|
Interleave real and imaginary data into a real array. |
|
Unpack complex data into an interleaved real, imaginary array. |
|
Unpacks complex array into real array (interleaves values). |
|
Seperate interleaved real, imaginary data into complex array. |
|
Seperate interleaved real, imaginary data into complex array. |
|
Packs interleaved real array into complex array. |
|
Decode data collected using States (seperates interleaved data). |
|
Append imaginary data to end of real data, returning a real array. |
|
Append imaginary data to end of real data, returning a real array. |
|
Unappend real and imaginary data returning a complex array. |
|
Unappend real and imaginary data returning a complex array. |
|
Exchange left and right halves of array. |
|
Exchange left and right halves of array. |
|
Rotate left and right halves of array. |
|
Rotate left and right halves of array. |
|
Swap real and imaginary data. |
|
Swap real and imaginary data. |
|
Byteswap data |
|
Byteswap data |
|
Negate left half. |
|
Negate right half. |
|
Negate middle half. |
|
Negate edge half (non-middle) of spectra. |
|
Negate data |
|
Negate real data |
|
Negate imaginary data |
|
Negate even points |
|
Negate odd points |
|
Negate alternate (odd) points. |
|
Replace data with absolute value of data (abs of real, imag seperately) |
|
Replace data with sign (-1 or 1) of data (seperately on each channel) |
Misc
|
Coadd data. |
|
Coadd data. |
|
Mark values less than thres as invalid (for use with filters) |
|
Convolute data with kernel. |
|
Convolute data with kernel. |
|
Correlate data with a kernel (weights). |
|
Correlate data with a kernel (weights). |
|
Apply a median filter. |
|
Apply a minimum filter. |
|
Apply a maximum filter. |
|
Apply a percentile filter. |
|
Apply a rank filter. |
|
Apply an absolute minimum filter. |
|
Apply an absolute maximum filter. |
|
Apply a range filter. |
|
Apply an average filter. |
|
Apply a standard deviation filter. |
|
Apply a summation filter. |
|
Apply a generic filter. |
|
Reorder spectrum after FT transform to NMR order (swap halves and reverse). |
|
Scale Quad Artifacts. |
|
Scale quad artifacts by values from Gram-Schmidt orthogonalization. |
|
Calculate Gram-Schmidt orthogonalization parameters. |
|
Mix input and output channels provided coefficient array. |
|
Smooth data. |
|
Center data. |
|
Zero Diagonal band with generic window function. |
|
Zero diagonal band with a boxcar function. |
|
Zero diagonal band with triangle function |
|
Zero diagonal band with sinebell function. |
|
Zero Diagonal band with gaussian function |
Low-Level Functions
The following are functions called by other processing functions. They are included here for completeness.
|
Integer to binary string |
|
binary string to integer |
|
Calculate n-bit gray code |
|
|
|
|
|
|
|
|
|
|
|
|
|
Find the nearest power of two equal to or larger than a value. |