CSM NMR Spectra


ectra < csm_spectra

NMR spectral Object. Contains X, PPM scale and various metadata.

Extends csm_spectra; see csm_spectra for more information.

csm_nmr_spectra.getSubSpectra( conditions ) will return a spectra based on the fields in sampleInfo.

conditions is the format {{ field, condition }}, and multiple conditions can be specified

ie:

conditions = {{ 'HistoScore', 'HS2' } ,{ 'RatNumber', '34' }}

csm_nmr_spectra.removeWater() will cur 4.7-4.9 ppm if sample_type = urine, 4.55-4.9

if serum/plasma or 4.699 to 4.9 by default.

Usage

spectra = csm_nmr_spectra( X, ppm );

spectra = csm_nmr_spectra( X, ppm, 'sample_type',sample_type,'pulse_program', pulse_program, 'name', name, 'is_continous', is_continuous, 'sample_ids', sample_ids, 'sample_metadata', sample_metadata, 'nmr_experiment_info', nmr_experiment_info, 'nmr_calibration_info', nmr_calibration_info );

Arguments (* = required)

VariableTypeDefault ValueDescription
*Xm*nNonespectral matrix.
*ppm1*nNonePPM Scale.
namestrNoneName of the data structure.
is_continuousbooltrueWhether the x scale is continuous
sample_idscell{}Sample IDs. Use the numeric index to match to the row
sample_metadatacsm_sample_metadataNoneMetadata from import.
nmr_experiment_infocsm_nmr_experiment_info NoneNMR experiment info from import.
nmr_calibration_infocsm_nmr_calibration_infoNoneNMR calibration info from import.
pulse_programstrNoneShortened version of the pulseprogram
sample_typestrNoneSample Type

Returns

VariableTypeDescription
csm_nmr_spectracsm_nmr_spectraCsm NMR spectra object.
csm_nmr_spectra.Xm*nspectral Matrix.
csm_nmr_spectra.ppm1*nPPM Scale.
csm_nmr_spectra.namestrName of the data structure.
csm_nmr_spectra.sample_idscellSample IDs, using a numeric index.
csm_nmr_spectra.sample_metadatacsm_import_sample_metadataSample Metadata from import.
csm_nmr_spectra.nmr_experiment_infocsm_import_nmr_experiment_infoNMR Experiment Info from import.
csm_nmr_spectra.nmr_calibration_infocsm_import_nmr_calibration_infoNMR Calibration Info from import.
csm_nmr_spectra.audit_infocsm_audit_infoAudit Info object.

Methods

MethodDescription
csm_nmr_spectra.setX( X )Assign a new X matrix to the object.
csm_nmr_spectra.setxScale( name, scale )Assign a new PPM to the object.
csm_nmr_spectra.importSampleInfo( sample_metadata_path )Import sample metadata.
csm_nmr_spectra.getSubSpectra( conditions )Return sub spec based on sampleInfo conditions. See description.
csm_nmr_spectra.addSpectra( spectra )Add a spectra object to this one.
csm_nmr_spectra.cutRegion( start , stop )Remove a section from start to stop.
csm_nmr_spectra.removeTSP()Removes the section -0.2 to 0.2.
csm_nmr_spectra.removeWater()Removes the section 4.669 to 4.9 by default. See description for more information.
csm_nmr_spectra.removeUrea()Removes the section 5.48 to 6.23.

Copyright Imperial College London 2019