MIXTURESTRING2MIXTURETABLE - convert a mixture string to a mixture table
T = MIXTURESTRING2MIXTURETABLE(STR, MIXTURESTRUCT)
Converts a mixture string STR to a table of mixtures.
STR is a string of the form "v1,v2,N*v3", etc. It indicates what
mixtures, which are fields of the MIXTURESTRUCT, are present here.
MIXTURESTRUCT is a structure with fields equal to the possibly mixture
type values V. The entries of MIXTURESTRUCT.V are a structure array with the following
values:
ontologyName : Node name of the compound in an ontology
name : The name of the compound (official name in the ontology)
value : The value of the concentration of the mixture
ontologyUnit : The unit of measure, usually 'OM:MolarVolumeUnit'
unitName : The name of the unit, usually 'Molar'
Example:
str = 'normal_saline,10e-4 ptx';
marderFolder = fullfile(ndi.common.PathConstants.RootFolder,'+ndi','+setup','+conv','+marder');
mixtureStruct = jsondecode(fileread(fullfile(marderFolder,"marder_mixtures.json")));
t = ndi.setup.conv.marder.mixtureString2mixtureTable((str,mixtureStruct)
% a table of entries