Hi Yikan,

I'm attaching a script (energyPlot.py) to plot the value of the different 
energy terms throughout a run, as reported in the log file.  For example, to 
plot the value of the "impr" term vs. the print count (which counts the times 
the energy has been printed in the log file), type the following in the command 
line:


energyPlot.py IMPR < log.out &


(where log.out is the specified log file).  If you omit the energy term above, 
all are printed.


I hope this helps.


Guillermo



________________________________
From: ZhangYikan <[email protected]>
Sent: Monday, December 11, 2017 6:25 PM
To: Bermejo, Guillermo (NIH/CIT) [E]; [email protected]
Subject: Re: [Xplor-nih] Wrong topology structures in conformational sampling

hello Guillermo,
Thank you for your scripts, I have tried it. I found that there are still some 
wrong topology structures and clahes(some overlaps):1) I will try to fix the 
repel parameter and rerun the script;
2) in the outputs of the previous zp_0-3.py, I found the terms of “impr” seems 
unusual(in the .viols), did you have some tools to analysis this energy term ?

Thank you!
Best,

Yikan
Ph. D candidate
TsingHua University
School of life Sciences
Beijing, China
tel:010-62773783



在 2017年12月12日,上午2:00,Bermejo, Guillermo (NIH/CIT) [E] 
<[email protected]<mailto:[email protected]>> 写道:

Hi Yikan,

I notice that your script seems to be more complicated than it has to be.  I'm 
not sure this will solve your problem, but I'm attaching a simpler script based 
on eginput/rna/fold.py.   It's basically the script used to fold an RNA 
molecule from an extended conformation (described in the paper I mentioned 
before).  I modified it so that you load your input pdb structure and define 
the different rigid bodies (look for the lines with an inline comment "# 
COMPLETE !", where you must enter the right information).  Then, it does 
torsion angle dynamics using the remaining torsional degrees of freedom (i.e., 
at the linker(s)).

I commented all the experimental restraints.  If you want to have the radius of 
gyration term (which appears in your script), you can introduce it yourself.  
Also, you might want to use it as a starting point for more complicated stuff, 
like "breaking" the linkers and randomizing the position of the domains.

A suggestion to try to avoid (and detect) knotted structures is to increase the 
atomic radii (see the 'repel' argument in initRepel).

Best,

Guillermo

________________________________
From: ZhangYikan <[email protected]<mailto:[email protected]>>
Sent: Monday, December 11, 2017 10:43 AM
To: Bermejo, Guillermo (NIH/CIT) [E]; 
[email protected]<mailto:[email protected]>
Subject: Re: [Xplor-nih] Wrong topology structures in conformational sampling

hello Guillermo,

I want these domains move (as rigid body)randomly and freely to sample all 
possible conformations of the RNA.

Yikan
Ph. D candidate
TsingHua University
School of life Sciences
Beijing, China
tel:010-62773783



在 2017年12月11日,下午11:27,Bermejo, Guillermo (NIH/CIT) [E] 
<[email protected]<mailto:[email protected]>> 写道:

Hi Yikan,

Can you tell me what you are trying to do?

Best,

Guillermo


________________________________
From: ZhangYikan <[email protected]<mailto:[email protected]>>
Sent: Friday, December 8, 2017 6:56 PM
To: Bermejo, Guillermo (NIH/CIT) [E]; 
[email protected]<mailto:[email protected]>
Subject: Re: [Xplor-nih] Wrong topology structures in conformational sampling

hi Guillermo,
yes, i have received your last mails. And the attachment is my scripts.


Yikan
Ph. D candidate
TsingHua University
School of life Sciences
Beijing, China
tel:010-62773783



在 2017年12月9日,上午12:43,Bermejo, Guillermo (NIH/CIT) [E] 
<[email protected]<mailto:[email protected]>> 写道:


Hi Yikan,

I realized that my original response was only sent to you and not included in 
the mailing list.   Here it is.

One possibility is that there's something wrong with your script(s).

I recommend basing your calculations on the scripts found in eginput/rna 
directory (within your Xplor-NIH directory).  There you'll find:

* fold.py, for initial calculations starting from an extended conformation.
* refine.py, for subsequent refinement.

In addition, you'll find all the restraints for an example system, in case you 
want to play with the scripts before venturing into your data.  The scripts are 
highly commented, which should help in customizing them for your needs.  
There's also a paper describing them [Bermejo et al., 2016, Structure 24, 
806-815].

Best,

Guillermo




________________________________

From: 
[email protected]<mailto:[email protected]> 
<[email protected]<mailto:[email protected]>> 
on behalf of ZhangYikan <[email protected]<mailto:[email protected]>>
Sent: Friday, December 8, 2017 6:53 AM
To: [email protected]<mailto:[email protected]>
Subject: [Xplor-nih] Wrong topology structures in conformational sampling



hello all,

Recently, I am doing conformational sampling with Xplor-NIH. And I got many 
pdbs, but when I check them I found that some pdbs have wrong topology 
structures like the attachments(in the pink cycle ): The RNA linker did not run 
with the right way and It went through the helix. I have tried to pick the 
structures by the “total energy” or “repel” terms, but it make no sense. Are 
there someone know how to kick out these wrong structures or to void these 
errors in the sampling process? Thank you!
Yikan
Ph. D candidate
TsingHua University
School of life Sciences
Beijing, China
tel:010-62773783

<fold.py>

#!/usr/bin/env pyXplor

(opts,args) = xplor.parseArguments(('noLegend:0',
                                    'points:0',
                                    'vsTime:0',
                                    'printOut:0',
                                    'reset:1')
                                    )

plotLegend=True
plotVs='cnt'
style="-"
noMinimize=False
infilename=None
reset=None
printOut=False
for opt in opts:
    if opt[0]=='noLegend':
        plotLegend=False
        pass
    elif opt[0]=='vsTime':
        plotVs='time'
        noMinimize=True
        pass
    elif opt[0]=='points':
        style='*'
        pass
    elif opt[0]=='reset':
        reset=opt[1]
        pass
    elif opt[0]=='printOut':
        printOut=True
        pass
    elif opt[0]=='help-script':
        print usage
        sys.exit(0)
        pass
    pass

included=args

if len(included)==1:
    plotLegend=False
    pass

if infilename==None:
    from sys import stdin
else:
    stdin = file(infilename)
    pass

cnt=0
energyMode=False
from parseTools import readFloat
vals={}
names=set()
names.add('delta_t')
startTime=0
for line in stdin.readlines():
    if line.startswith("*--- Dynamics") or line.startswith(" -- PC6 "):
        if not vals.has_key(cnt): vals[cnt]={}
        buf=str(line)
        while "---" in buf:
            buf=buf.replace("---","--")
            pass
        fields=buf.split("--")
        step=int(fields[2].split('=')[1])
        time,dummy=readFloat(fields[3].split('=')[1])
        delta_t,dummy=readFloat(fields[4].split('=')[1])
        vals[cnt]['step'] = step
        try:
            if step==0 and cnt>0:
                startTime = vals[cnt-1]['time'] + vals[cnt-1]['delta_t']
                pass
            vals[cnt]['time'] = time+startTime
            vals[cnt]['delta_t'] = delta_t
            energyMode=True
        except KeyError:
            pass
        pass
    elif not noMinimize and (line.startswith("*-- POWELL") or
                             line.startswith(" --------------- cycle=") ):
        if not vals.has_key(cnt): vals[cnt]={}
        buf=str(line)
        while "---" in buf:
            buf=buf.replace("---","--")
            pass
        fields=buf.split("--")
        step=int(fields[2].split('=')[1])
        energyMode=True
        pass

    if reset and reset in line:
        cnt=0
        pass
    
    if (line.startswith("*--------------") or
        line.startswith(" ------------------------------")):
        cnt += 1
        energyMode=False
        pass
    if energyMode and (line.startswith("|") or
                       line.startswith(" |") ):
        buf=str(line[1:][:-1]).strip()
        if buf.startswith('|'): buf = buf[1:]
        while buf:
            pos=buf.find("=")
            if pos<0:
                break
            name=buf[:pos].strip()
            val,buf=readFloat(buf[pos+1:])
            names.add(name)
            vals[cnt][name] = val
            pass
        pass
    
        
    pass
indices=sorted(vals.keys())
#for name in names:
#    for index in indices:
#        print index,name,vals[cnt][name]
#        pass
#    pass

excluded=['temperature','E(kin)+E(poten)','E(kin)','E(poten)','grad']


import pylab
import matplotlib
fig=pylab.figure()
ax = fig.add_axes((0.1,0.1,0.86,0.85))

legendLabels=[]
curves=[]
for name in names:
    if included:
        if not name in included:
            continue
        pass
    elif name in excluded:
        continue
    y=[]
    x=[]
    for index in indices:
        if name in vals[index].keys():
            y.append(vals[index][name])
            x.append(index)
            if printOut:
                print name, x[-1], y[-1]
            pass
        pass
    if plotVs=='time':
        x=[vals[index]['time'] for index in x]
        pass
    legendLabels.append(name)
    curves.append( ax.plot(x,y,style,label=name) )
    pass

if plotLegend:
    ax.legend(legendLabels)
    pass

if not printOut:
    pylab.show()
    pass
_______________________________________________
Xplor-nih mailing list
[email protected]
https://dcb.cit.nih.gov/mailman/listinfo/xplor-nih

Reply via email to