nmrglue.fileiobase

fileiobase provides general purpose NMR file IO functions and classes used by multiple nmrglue.fileio modules.

This modules is imported as nmrglue.fileiobase and can be called as such.

Developer Information

Developer Functions

These functions are typically not used directly by users. They are called by high level functions.

create_blank_udic(ndim)

Create a blank universal dictionary for a spectrum of dimension ndim.

uc_from_udic(udic[, dim])

Create a unit conversion object from a Universal dictionary.

uc_from_freqscale(scale, obs[, unit])

Create a unit conversion object from a spectrum frequency scale axis.

open_towrite(filename[, overwrite, mode])

Open filename for writing and return file object

ndfrom_iter(shape, slices)

ndto_iter(shape, slices)

ndtofrom_iter(shape, slices)

size_and_ndtofrom_iter(shape, slices)

index2trace_flat(shape, index)

Calculate trace number from shape and index of all indirect dimensions assuming a flat structure

trace2index_flat(shape, ntrace)

Calculate the index of a trace assuming a flat structure

index2trace_opp(shape, index)

Calculate trace number from shape and index of all indirect dimensions assuming a phase ordering opposite the time increments.

trace2index_opp(shape, ntrace)

Calculate the index of a trace assuming opposite phase/time increment ordering

index2trace_reg(shape, index)

Calculate trace number from shape and index of all indirect dimensions assuming the same phase and time ordering.

trace2index_reg(shape, ntrace)

Calculate the index of a trace assuming the same phase/time increment ordering

Developer Classes

These classes are typically not used directly by users. Developers may be interested in these classes.

unit_conversion(size, cplx, sw, obs, car)

Provides methods to convert between common NMR units

data_nd(order)

Base class for building objects which emulate ndarray objects without loading data into memory.