Dear Pymol users, dear Friends!

I have a question regarding file conversion of the small organic
molecules, which is not directly related to pymol but I believe that I
may use it for the solution.

I am dealing with the conversion of SDF file (2d formulas) to mol2
format (3d coordinates)
Usually I use it in one line command with babel
obabel --gen3d -isdf ligands.sdf -omol2 > ligands.mol2

It creates a multi-model mol2 file, that I may open in pymol and split
the molecules manually using split_states command:
pymol ligands.mol2
cmd.split_states('ligands', 'prefix=conf')
This creates several separate objects conf0001, conf0002 etc that I
may save as the individual mol2.
Alternatively I may obtain individual mol2 filles for each model of the SDF:
obabel ./ligands.sdf -O ./babel/conf.mol2 --gen3d -m
which creates separate files conf1.mol2 , conf2.mol2 .. confN.mol2
that I may load in pymol in one command from terminal
pymol ./babel/conf*.mol2

The problem that the name of the initial model stored in the initial sdf, as:
 <ID_STRUCTURE>
name_of_the_ligand

always lost during conversion from sdf to mol2 (regardless of the way
of the conversion). So the mol2 files always lack their initials
defined from sdf :-)

Could you suggest some trick to associate the name of the model (From
initial sdf) to the corresponding object loaded in pymol or
alternatively keep them during the conversion?
Many thanks in advance!
Enrico


_______________________________________________
PyMOL-users mailing list
Archives: http://www.mail-archive.com/pymol-users@lists.sourceforge.net
Unsubscribe: 
https://sourceforge.net/projects/pymol/lists/pymol-users/unsubscribe

Reply via email to