Man pages for spant
MR Spectroscopy Analysis Tools

abfit_optsReturn a list of options for an ABfit analysis.
abfit_opts_v1_9_0Return a list of options for an ABfit analysis to maintain...
acquireSimulate pulse sequence acquisition.
add_noiseAdd noise to an mrs_data object.
add_noise_spec_snrAdd noise to an mrs_data object to match a given SNR.
alignAlign spectra to a reference frequency using a convolution...
apodise_xyApodise MRSI data in the x-y direction with a k-space filter.
append_basisCombine a pair of basis set objects.
append_coilsAppend MRS data across the coil dimension, assumes they...
append_dynsAppend MRS data across the dynamic dimension, assumes they...
append_regsAppend multiple regressor data frames into a single data...
apply_axesApply a function over specified array axes.
apply_mrsApply a function across given dimensions of a MRS data...
apply_pulseSimulate an RF pulse on a single spin.
Arg.mrs_dataApply Arg operator to an MRS dataset.
array2mrs_dataConvert a 7 dimensional array in into a mrs_data object. The...
auto_phasePerform zeroth-order phase correction based on the...
back_extrap_arBack extrapolate time-domain data points using an...
basis2dyn_mrs_dataConvert a basis object to a dynamic mrs_data object.
basis2mrs_dataConvert a basis object to an mrs_data object - where basis...
bbaseGenerate a spline basis, slightly adapted from : "Splines,...
bc_alsBaseline correction using the ALS method.
bc_constantRemove a constant baseline offset based on a reference...
bc_gaussApply and subtract a Gaussian smoother in the spectral...
bc_polyFit and subtract a polynomial to each spectrum in a dataset.
bc_splineFit and subtract a smoothing spline to each spectrum in a...
beta2lwCovert a beta value in the time-domain to an equivalent...
bin_specBin equally spaced spectral regions.
calc_basis_corr_matEstimate the correlation matrix for a basis set.
calc_basis_crlbsEstimate the CRLB for each element in a basis set.
calc_coil_noise_corCalculate the noise correlation between coil elements.
calc_coil_noise_sdCalculate the noise standard deviation for each coil element.
calc_design_efficiencyCalculate the efficiency of a regressor data frame.
calc_ed_from_lambdaCalculate the effective dimensions of a spline smoother from...
calc_peak_info_vecCalculate the FWHM of a peak from a vector of intensity...
calc_sd_polyPerform a polynomial fit, subtract and return the standard...
calc_spec_diffCalculate the sum of squares differences between two mrs_data...
calc_spec_snrCalculate the spectral SNR.
check_lcmCheck LCModel can be run
check_tqnCheck the TARQUIN binary can be run
circ_maskCreate a logical circular mask spanning the full extent of an...
coherence_filterZero all coherence orders other than the one supplied as an...
collapse_to_dynsCollapse MRS data by concatenating spectra along the dynamic...
comb_coilsCombine coil data based on the first data point of a...
comb_coils_mrsi_glsCombine MRSI coil data using the GLS method presented by An...
comb_coils_svs_glsCombine SVS coil data using the GLS method presented by An et...
comb_fit_list_fit_tablesCombine all fitting data points from a list of fits into a...
comb_fit_list_result_tablesCombine the fit result tables from a list of fit results.
comb_fit_tablesCombine all fitting data points into a single data frame.
comb_metab_refCombine a reference and metabolite mrs_data object.
Conj.mrs_dataApply Conj operator to an MRS dataset.
conv_mrsConvolve two MRS data objects.
crop_basisCrop 'basis_set' object based on a frequency range.
crop_specCrop 'mrs_data' object based on a frequency range.
crop_td_ptsCrop 'mrs_data' object data points in the time-domain.
crop_td_pts_endCrop 'mrs_data' object data points at the end of the FID.
crop_td_pts_potCrop 'mrs_data' object data points in the time-domain...
crop_xyCrop an MRSI dataset in the x-y direction
crossprod_3dCompute the vector cross product between vectors x and y....
decimate_mrs_fdDecimate an MRS signal to half the original sampling...
decimate_mrs_tdDecimate an MRS signal by filtering in the time domain before...
deconv_mrsDeconvolve two MRS data objects.
def_acq_parasReturn (and optionally modify using the input arguments) a...
def_fsReturn the default sampling frequency in Hz.
def_ftReturn the default transmitter frequency in Hz.
def_NReturn the default number of data points in the spectral...
def_nucReturn the default nucleus.
def_refReturn the default reference value for ppm scale.
dicom_readerA very simple DICOM reader.
diff_mrsApply the diff operator to an MRS dataset in the FID/spectral...
downsample_mrs_fdDownsample an MRS signal by a factor of 2 using an FFT...
downsample_mrs_tdDownsample an MRS signal by a factor of 2 by removing every...
dyn_acq_timesReturn a time scale vector of acquisition times for a dynamic...
eccEddy current correction.
elliptical_maskCreate an elliptical mask stored as a matrix of logical...
est_noise_sdEstimate the standard deviation of the noise from a segment...
fd2tdTransform frequency-domain data to the time-domain.
fd_conv_filtFrequency-domain convolution based filter.
fd_gauss_smoApply a Gaussian smoother in the spectral domain.
find_bids_mrsSearch for MRS data files in a BIDS filesystem structure.
find_mrs_filesFind valid MRS data files recursively from a directory path.
fit_ampsExtract the fit amplitudes from an object of class...
fit_diagsCalculate diagnostic information for object of class...
fit_mrsPerform a fit based analysis of MRS data.
fit_res2csvWrite fit results table to a csv file.
fit_t1_ti_arrayFit a T1 recovery curve, from multiple TIs, to a set of...
fit_t1_tr_arrayFit a T1 recovery curve, from multiple TRs, to a set of...
fit_t2_te_arrayFit a T2 relaxation curve, from multiple TEs, to a set of...
fp_phaseReturn the phase of the first data point in the time-domain.
fp_phase_correctPerform a zeroth order phase correction based on the phase of...
fp_scaleScale the first time-domain data point in an mrs_data object.
fsReturn the sampling frequency in Hz of an MRS dataset.
ft_dynsApply the Fourier transform over the dynamic dimension.
ft_shiftPerform a fft and ffshift on a vector.
ft_shift_matPerform a fft and fftshift on a matrix with each column...
gausswin_2dCreate a two dimensional Gaussian window function stored as a...
gen_baseline_regGenerate baseline regressor.
gen_bold_regGenerate BOLD regressors.
gen_conv_regGenerate regressors by convolving a specified response...
gen_FGenerate the F product operator.
gen_F_xyGenerate the Fxy product operator with a specified phase.
gen_group_regExpand a regressor matrix for a group analysis.
gen_IGenerate the I product operator for a single spin.
gen_impulse_regGenerate impulse regressors.
gen_poly_regGenerate polynomial regressors.
gen_trap_regGenerate trapezoidal regressors.
get_1h_brain_basis_namesReturn a character vector of common 1H molecules found in...
get_1h_brain_basis_parasReturn a list of 'mol_parameter' objects suitable for 1H...
get_1h_brain_basis_paras_v1Return a list of 'mol_parameter' objects suitable for 1H...
get_1h_brain_basis_paras_v2Return a list of 'mol_parameter' objects suitable for 1H...
get_1h_brain_basis_paras_v3Return a list of 'mol_parameter' objects suitable for 1H...
get_1h_braino_basis_namesReturn a character vector of molecules included in the GE...
get_1h_spectre_basis_namesReturn a character vector of molecules included in the Gold...
get_2d_psfGet the point spread function (PSF) for a 2D phase encoded...
get_acq_parasReturn acquisition parameters from a MRS data object.
get_basis_subsetReturn a subset of the input basis.
get_dynsExtract a subset of dynamic scans.
get_even_dynsReturn even numbered dynamic scans starting from 1...
get_fh_dynsReturn the first half of a dynamic series.
get_fit_mapGet a data array from a fit result.
get_fpReturn the first time-domain data point.
get_guassian_pulseGenerate a gaussian pulse shape.
get_head_dynsReturn the first scans of a dynamic series.
get_lcm_cmdPrint the command to run the LCModel command-line program.
get_metabExtract the metabolite component from an mrs_data object.
get_mol_namesReturn a character array of names that may be used with the...
get_mol_parasGet a 'mol_parameters' object for a named molecule.
get_mrs_affineGenerate an affine for nifti generation.
get_mrsi2d_segCalculate the partial volume estimates for each voxel in a 2D...
get_mrsi_voiGenerate a MRSI VOI from an 'mrs_data' object.
get_mrsi_voxelGenerate a MRSI voxel from an 'mrs_data' object.
get_mrsi_voxel_xy_psfGenerate a MRSI voxel PSF from an 'mrs_data' object.
get_odd_dynsReturn odd numbered dynamic scans starting from 1 (1,3,5...).
get_refExtract the reference component from an mrs_data object.
get_seg_indGet the indices of data points lying between two values (end...
get_sh_dynsReturn the second half of a dynamic series.
get_sliceReturn a single slice from a larger MRSI dataset.
get_spin_numReturn the spin number for a given nucleus.
get_subsetExtract a subset of MRS data.
get_svs_voiGenerate a SVS acquisition volume from an 'mrs_data' object.
get_tail_dynsReturn the last scans of a dynamic series.
get_td_ampReturn an array of amplitudes derived from fitting the...
get_tqn_cmdPrint the command to run the TARQUIN command-line program.
get_uncoupled_molGenerate a 'mol_parameters' object for a simple spin system...
get_voi_cogCalculate the centre of gravity for an image containing 0 and...
get_voi_segReturn the white matter, gray matter and CSF composition of a...
get_voi_seg_psfReturn the white matter, gray matter and CSF composition of a...
get_voxelReturn a single voxel from a larger mrs dataset.
glm_specPerform a GLM analysis of dynamic MRS data in the spectral...
glm_spec_fmrs_flPerform first-level spectral GLM analysis of an fMRS dataset.
glm_spec_fmrs_groupPerform group-level spectral GLM analysis of an fMRS dataset.
glm_spec_group_linhypTest a group-level spectral GLM linear hypothesis.
gridplotArrange spectral plots in a grid.
gridplot.mrs_dataArrange spectral plots in a grid.
grid_shift_xyGrid shift MRSI data in the x/y dimension.
hsvdHSVD of an mrs_data object.
hsvd_filtHSVD based signal filter.
hsvd_vecHSVD of a complex vector.
hzReturn the frequency scale of an MRS dataset in Hz.
ift_shiftPerform an iffshift and ifft on a vector.
ift_shift_matPerform an ifft and ifftshift on a matrix with each column...
image.mrs_dataImage plot method for objects of class mrs_data.
img2kspace_xyTransform 2D MRSI data to k-space in the x-y direction.
Im.mrs_dataApply Im operator to an MRS dataset.
ImzapComplex rounding function taken from complexplus package to...
interleave_dynsInterleave the first and second half of a dynamic series.
int_specIntegrate a spectral region.
inv_even_dynsInvert even numbered dynamic scans starting from 1...
inv_odd_dynsInvert odd numbered dynamic scans starting from 1 (1,3,5...).
is.defCheck if an object is defined, which is the same as being not...
is_fdCheck if the chemical shift dimension of an MRS data object...
kspace2img_xyTransform 2D MRSI data from k-space to image space in the x-y...
l2_regPerform l2 regularisation artefact suppression.
lbApply line-broadening (apodisation) to MRS data or basis...
lofdcCorrect linear frequency drift.
lw2alphaCovert a linewidth in Hz to an equivalent alpha value in the...
lw2betaCovert a linewidth in Hz to an equivalent beta value in the...
make_basis_from_rawMake a basis-set object from a directory containing LCModel...
mask_dynsMask an MRS dataset in the dynamic dimension.
mask_fit_resMask fit result spectra depending on a vector of bool values.
mask_xyMask an MRSI dataset in the x-y direction
mask_xy_cornersMask the four corners of an MRSI dataset in the x-y plane.
mask_xy_ellipseMask the voxels outside an elliptical region spanning the...
mask_xy_matMask a 2D MRSI dataset in the x-y dimension.
mat2mrs_dataConvert a matrix (with spectral points in the column...
matexpMatrix exponential function taken from complexplus package to...
max_mrsApply the max operator to an MRS dataset.
max_mrs_interpApply the max operator to an interpolated MRS dataset.
mean_dyn_blocksCalculate the mean of adjacent dynamic scans.
mean_dyn_pairsCalculate the pairwise means across a dynamic data set.
mean_dynsCalculate the mean dynamic data.
mean.listCalculate the mean spectrum from an mrs_data object.
mean.mrs_dataCalculate the mean spectrum from an mrs_data object.
mean_mrs_listReturn the mean of a list of mrs_data objects.
mean_vec_blocksCalculate the mean of adjacent blocks in a vector.
median_dynsCalculate the median dynamic data.
Mod.mrs_dataApply Mod operator to an MRS dataset.
mod_tdApply the Modulus operator to the time-domain MRS signal.
mrs_data2basisConvert an mrs_data object to basis object - where basis...
mrs_data2bidsCreate a BIDS file structure from a vector of MRS data paths...
mrs_data2matConvert mrs_data object to a matrix, with spectral points in...
mrs_data2spec_matConvert mrs_data object to a matrix, with spectral points in...
mrs_data2vecConvert mrs_data object to a vector.
mvfftshiftPerform a fftshift on a matrix, with each column replaced by...
mvifftshiftPerform an ifftshift on a matrix, with each column replaced...
n2coordPrint fit coordinates from a single index.
NcoilsReturn the total number of coil elements in an MRS dataset.
NdynsReturn the total number of dynamic scans in an MRS dataset.
nifti_flip_lrFlip the x data dimension order of a nifti image. This...
NptsReturn the number of data points in an MRS dataset.
NspecReturn the total number of spectra in an MRS dataset.
NtransReturn the total number of acquired transients for an MRS...
NxReturn the total number of x locations in an MRS dataset.
NyReturn the total number of y locations in an MRS dataset.
NzReturn the total number of z locations in an MRS dataset.
one_page_pdfExport a one-page pdf of a single fit result
ortho3Display an orthographic projection plot of a nifti object.
ortho3_interDisplay an interactive orthographic projection plot of a...
peak_infoSearch for the highest peak in a spectral region and return...
pg_extrap_xyPapoulis-Gerchberg (PG) algorithm method for k-space...
phaseApply phasing parameters to MRS data.
phase_ref_1h_brainCorrected zero order phase and chemical shift offset in 1H...
plot_bcConvenience function to plot a baseline estimate with the...
plot.fit_resultPlot the fitting results of an object of class 'fit_result'.
plot.mrs_dataPlotting method for objects of class mrs_data.
plot_regPlot regressors as an image.
plot_slice_fitPlot a 2D slice from an MRSI fit result object.
plot_slice_fit_interPlot a 2D slice from an MRSI fit result object.
plot_slice_mapPlot a slice from a 7 dimensional array.
plot_slice_map_interPlot an interactive slice map from a data array where voxels...
plot_spec_sdPlot the spectral standard deviation.
plot_voi_overlayPlot a volume as an image overlay.
plot_voi_overlay_segPlot a volume as an overlay on a segmented brain volume.
ppmReturn the ppm scale of an MRS dataset or fit result.
precompSave function results to file and load on subsequent calls to...
preproc_svsPreprocess and perform quality assessment of a single SVS...
preproc_svs_datasetPreprocess and perform quality assessment of one or more SVS...
print.fit_resultPrint a summary of an object of class 'fit_result'.
print.mrs_dataPrint a summary of mrs_data parameters.
qn_statesGet the quantum coherence matrix for a spin system.
ratsRobust Alignment to a Target Spectrum (RATS).
read_basisRead a basis file in LCModel .basis format.
read_ima_coil_dirRead a directory containing Siemens MRS IMA files and combine...
read_ima_dyn_dirRead a directory containing Siemens MRS IMA files and combine...
read_lcm_coordRead an LCModel formatted coord file containing fit...
read_mrsRead MRS data from a file.
read_mrs_tqnRead MRS data using the TARQUIN software package.
read_pulse_asciiRead an ASCII formatted pulse file.
read_pulse_brukerRead a Bruker formatted pulse file
read_pulse_ptaRead a .pta formatted pulse file compatible with Siemens...
read_siemens_txt_hdrRead the text format header found in Siemens IMA and TWIX...
read_tqn_fitReader for csv fit results generated by TARQUIN.
read_tqn_resultReader for csv results generated by TARQUIN.
recon_imagReconstruct complex time-domain data from the real part of...
recon_imag_vecReconstruct complex time-domain data from the real part of...
recon_twix_2d_mrsiReconstruct 2D MRSI data from a twix file loaded with...
rectangular_maskCreate a rectangular mask stored as a matrix of logical...
reexportsObjects exported from other packages
Re.mrs_dataApply Re operator to an MRS dataset.
rep_array_dimRepeat an array over a given dimension.
rep_dynReplicate a scan in the dynamic dimension.
rep_mrsReplicate a scan over a given dimension.
resample_basisResample a basis-set to match a mrs_data acquisition.
resample_imgResample an image to match a target image space.
resample_voiResample a VOI to match a target image space using...
reslice_to_mrsReslice a nifti object to match the orientation of mrs data.
reson_table2mrs_dataGenerate mrs_data from a table of single Lorentzian...
re_weightingApply a weighting to the FID to enhance spectral resolution.
rm_dynsRemove a subset of dynamic scans.
scale_amp_molalApply water reference scaling to a fitting results object to...
scale_amp_molal_pvcApply water reference scaling to a fitting results object to...
scale_amp_molarApply water reference scaling to a fitting results object to...
scale_amp_molar2molal_pvcConvert default LCM/TARQUIN concentration scaling to molal...
scale_amp_ratioScale fitted amplitudes to a ratio of signal amplitude.
scale_amp_ratio_valueScale fitted amplitudes to a ratio of signal amplitude.
scale_amp_water_ratioScale metabolite amplitudes as a ratio to the unsuppressed...
scale_basis_ampScale a basis object by a scalar.
scale_basis_from_singletScale a basis-set to be consistent with spant assumptions for...
scale_mrs_ampScale an mrs_data object by a scalar or vector or amplitudes.
scale_specScale mrs_data to a spectral region.
sdCalculate the standard deviation spectrum from an mrs_data...
sd.mrs_dataCalculate the standard deviation spectrum from an mrs_data...
secondsReturn a time scale vector to match the FID of an MRS data...
seq_cpmg_idealCPMG style sequence with ideal pulses.
seq_mega_press_idealMEGA-PRESS sequence with ideal localisation pulses and...
seq_press_2d_shapedPRESS sequence with shaped refocusing pulses.
seq_press_idealPRESS sequence with ideal pulses.
seq_pulse_acquireSimple pulse and acquire sequence with ideal pulses.
seq_slaser_idealsLASER sequence with ideal pulses.
seq_spin_echo_idealSpin echo sequence with ideal pulses.
seq_steam_idealSTEAM sequence with ideal pulses.
seq_steam_ideal_cofSTEAM sequence with ideal pulses and coherence order...
seq_steam_ideal_youngSTEAM sequence with ideal pulses using the z-rotation...
set_def_acq_parasSet the default acquisition parameters.
set_lcm_cmdSet the command to run the LCModel command-line program.
set_lwApply line-broadening to an mrs_data object to achieve a...
set_mask_xy_matSet the masked voxels in a 2D MRSI dataset to given spectrum.
set_NtransSet the number of transients for an mrs_data object.
set_precomp_modeSet the precompute mode.
set_precomp_verboseSet the verbosity of the precompute function.
set_refSet the ppm reference value (eg ppm value at 0Hz).
set_td_ptsSet the number of time-domain data points, truncating or...
set_tqn_cmdSet the command to run the TARQUIN command-line program.
set_trSet the repetition time of an MRS dataset.
shiftApply a frequency shift to MRS data.
shift_basisApply frequency shifts to basis set signals.
sim_basisSimulate a basis set object.
sim_basis_1h_brainSimulate a basis-set suitable for 1H brain MRS analysis...
sim_basis_1h_brain_pressSimulate a basis-set suitable for 1H brain MRS analysis...
sim_basis_mm_lip_lcmSimulate a macromolecular and lipid basis-set suitable for 1H...
sim_basis_tqnSimulate a basis file using TARQUIN.
sim_brain_1hSimulate MRS data with a similar appearance to normal brain...
sim_molSimulate a 'mol_parameter' object.
sim_noiseSimulate an mrs_data object containing simulated Gaussian...
sim_resonancesSimulate a MRS data object containing a set of simulated...
sim_th_excit_profileSimulate an ideal pulse excitation profile by smoothing a...
sim_zeroSimulate an mrs_data object containing complex zero valued...
smooth_dynsSmooth data across the dynamic dimension with a Gaussian...
sort_basisSort the basis-set elements alphabetically.
spant_abfit_benchmarkSimulate and fit some spectra with ABfit for benchmarking...
spant_mpress_driftExample MEGA-PRESS data with significant B0 drift.
spant-packagespant: spectroscopy analysis tools.
spant_sim_fmrs_datasetSimulate an example fMRS dataset for a block design fMRS...
spant_simulation_benchmarkSimulate a typical metabolite basis set for benchmarking....
spec_decompDecompose an mrs_data object into white and gray matter...
spec_opPerform a mathematical operation on a spectral region.
spin_sysCreate a spin system object for pulse sequence simulation.
spm_pve2categoricalConvert SPM style segmentation files to a single categorical...
sspSignal space projection method for lipid suppression.
stackplotProduce a plot with multiple traces.
stackplot.fit_resultPlot the fitting results of an object of class 'fit_result'...
stackplot.mrs_dataStackplot plotting method for objects of class mrs_data.
sub_first_dynSubtract the first dynamic spectrum from a dynamic series.
sub_mean_dynsSubtract the mean dynamic spectrum from a dynamic series.
sub_median_dynsSubtract the median dynamic spectrum from a dynamic series.
sum_coilsCalculate the sum across receiver coil elements.
sum_dynsCalculate the sum of data dynamics.
sum_mrsSum two mrs_data objects.
sum_mrs_listReturn the sum of a list of mrs_data objects.
svs_1h_brain_analysisStandard SVS 1H brain analysis pipeline.
svs_1h_brain_analysis_devStandard SVS 1H brain analysis pipeline.
svs_1h_brain_batch_analysisBatch interface to the standard SVS 1H brain analysis...
td2fdTransform time-domain data to the frequency-domain.
td_conv_filtTime-domain convolution based filter.
tdsrTime-domain spectral registration.
teReturn the echo time of an MRS dataset.
trReturn the repetition time of an MRS dataset.
t_test_specPerform a t-test on spectral data points.
varpro_3_para_optsReturn a list of options for VARPRO based fitting with 3 free...
varpro_basic_optsReturn a list of options for a basic VARPRO analysis.
varpro_optsReturn a list of options for VARPRO based fitting.
vec2mrs_dataConvert a vector into a mrs_data object.
write_basisWrite a basis object to an LCModel .basis formatted file.
write_basis_tqnGenerate a basis file using TARQUIN.
write_mrsWrite MRS data object to file.
write_mrs_niftiWrite MRS data object to file in NIFTI format.
write_pulse_asciiWrite an ASCII formatted pulse file.
zero_fade_specFade a spectrum to zero by frequency domain multiplication...
zero_higher_ordersZero all coherences including and above a given order.
zero_td_pts_endSet 'mrs_data' object data points at the end of the FID to...
zfZero-fill MRS data in the time domain.
zf_xyZero-fill MRSI data in the k-space x-y direction.
spant documentation built on Sept. 11, 2024, 9:13 p.m.