File tree Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -161,7 +161,16 @@ function getatomdictfromrmg(mol)
161
161
molecularweight = mol. get_molecular_weight ()
162
162
return atmD,nbonds,molecularweight
163
163
end
164
- getatomdictsmiles (smiles) = getatomdictfromrdkit (Chem. AddHs (Chem. MolFromSmiles (smiles)))
164
+ function getatomdictsmiles (smiles)
165
+ if occursin (r" R" , smiles) || occursin (r" L" , smiles)
166
+ mol = fragment. Fragment (). from_smiles_like_string (smiles)
167
+ mol. assign_representative_molecule ()
168
+ getatomdictfromrmg (mol. mol_repr)
169
+ else
170
+ getatomdictfromrdkit (Chem. AddHs (Chem. MolFromSmiles (smiles)))
171
+ end
172
+ end
173
+
165
174
export getatomdictsmiles
166
175
getatomdictinchi (inchi) = getatomdictfromrdkit (Chem. AddHs (Chem. MolFromInchi (inchi)))
167
176
export getatomdictinchi
You can’t perform that action at this time.
0 commit comments