Commit 27e2d150 authored by William Clarke's avatar William Clarke
Browse files

Merge remote-tracking branch 'pr/patch-1'

Merge PR from github fixing issue with metabolite group parsing.
parents a5fcdf8e fde5c9c7
......@@ -607,9 +607,16 @@ def parse_metab_groups(mrs,metab_groups):
if metab_groups.lower() == 'combine_all':
return [0]*mrs.numBasis
out = [0]*mrs.numBasis
out[mrs.names.index(metab_groups)] = 1
entry = metab_groups.split('+')
if isinstance(entry,str):
out[mrs.names.index(entry)] = 1
elif isinstance(entry,list):
for n in entry:
assert(isinstance(n,str))
out[mrs.names.index(n)] = 1
return out
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment