[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [ccp4bb]: Deleting by Chain ID



***  For details on how to be removed from this list visit the  ***
***          CCP4 home page http://www.ccp4.ac.uk         ***

(sorry for possible duplication - I'm suffering from mailer problems)

On Monday 18 February 2002 10:08, Paul Hubbard wrote:

> I am looking at an output file generated by FFFEAR, where lots of
> potential helices are written to a PDB file. Each helix candidate is
> written with a different chain ID. I would like to jump to each
> consecutive chain, then delete the whole chain in one go if I don't like
> it.
>
> My question is, what's the best way to do this. I have played with XFIT,
> and can't seem to do it there except by deleting 1 residue at a time.

I don't have an existing Xfit script to offer for that exact use, but here 
is how I would approach it.

1) Load a copy of the FFFEAR PDB file into a running copy of Xfit
2) Write perl (or csh) script that extracts each chain from the original
    PDB file and emits commands to create a singe view object from it
3) Pipe these emitted commands to the file/pipe defined by 
    XFIT_UPDATESCRIPT, so that Xfit displays each in a separate
    view object
4) Toggle through the view objects to select the ones you like
5)  Select these (or delete the others) with a simple grep command;
    e.g. to delete chain Q
	grep -v ' Q ' FFFEAR.pdb > no_q.pdb
    If you like, this also could be a scripted command that updates
    the active Xfit model via XFIT_UPDATESCRIPT

You could load them as separate models, rather than as view objects.
That would allow you to click on atoms for contact checks, etc.  
In that case you can just write out the models you like directly from the 
Xfit 'Files' menu.   I have written scripts to do something similar
to this so that I can use Xfit to scan through long lists of modelled 
ligand conformations written out by docking or ligand building programs.

Unfortunately the Xfit scripting commands are not well documented.
But what you can do is start a new sessin, manually go through the 
interactive process of achieving some simple operation (creating a
view object, say), and then save the session log to a script file.
Once you have an example script for this operation, it's not so bad to
use it as a template for emitting commands via XFIT_UPDATESCRIPT