Hey Dimitry,

The "quiet" option (if present) is set to zero by default for parsed PyMOL commands, but is not set for Python API calls.

align
is nearly equal to
cmd.align(quiet=0)

Thus, if you want to get rmsd output, include quiet=0 and run your script with output redirection.

The last line of your script should read
cmd.align(pdb.group(1) , '1gk9', quiet=0)
and the script should be called like this:

pymol -qa script > output


That's at least how it used to work.


Andreas



DimitryASuplatov wrote:
Hello, with your help I was able to write the following script to automatically
load 21 structure and align 20 of them to the remaining one.

*************************************************
import os
import re
from os.path import join, getsize

cmd.delete(all)
p = re.compile('[A-Za-z\.]*pdb')
w = re.compile('nowater')
for root, dirs, files in os.walk('./'):
    for file in files:
<------>if p.search(file) and w.search(file):
<------>    cmd.load(file)
    cmd.delete('1gk9*')
    cmd.fetch('1gk9')
    for file1 in files:
<------>if p.search(file1) and w.search(file1):
<------>    if re.search('1gk9', file1):
<------><------>continue
<------>    pdb = re.search('(.+)\.pdb', file1)
<------>    print pdb.group(1), ' and 1gk9'
<------>    cmd.align(pdb.group(1) , '1gk9')
*************************************************

The problem is that I see only the result - aligned structures. But I
want to see the RMSD values and apply them to scrip variables. Is that
possible?
Thank you.


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
PyMOL-users mailing list
PyMOL-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/pymol-users


--
        Andreas Förster, Research Associate
        Paul Freemont & Xiaodong Zhang Labs
Department of Biochemistry, Imperial College London

Reply via email to