<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class="">Thank you very much Elaine,<div class="">for a speedy answer, and also for the ~distance command!</div><div class="">I could do a series of GREPs to get my numbers out of the reply log, but I will first try to pursue Vinod’s kind offer.</div><div class=""><br class=""></div><div class="">Anne-Frances</div><div class=""><br class=""><div class="">
<div dir="auto" style="caret-color: rgb(0, 0, 0); color: rgb(0, 0, 0); letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div dir="auto" style="caret-color: rgb(0, 0, 0); color: rgb(0, 0, 0); letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div dir="auto" style="caret-color: rgb(0, 0, 0); color: rgb(0, 0, 0); letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div dir="auto" style="caret-color: rgb(0, 0, 0); letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div dir="auto" style="caret-color: rgb(0, 0, 0); letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div dir="auto" style="caret-color: rgb(0, 0, 0); letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div dir="auto" style="caret-color: rgb(0, 0, 0); letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div dir="auto" style="caret-color: rgb(0, 0, 0); letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div dir="auto" style="caret-color: rgb(0, 0, 0); letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div dir="auto" style="caret-color: rgb(0, 0, 0); letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div dir="auto" style="caret-color: rgb(0, 0, 0); letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div dir="auto" style="caret-color: rgb(0, 0, 0); letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div dir="auto" style="caret-color: rgb(0, 0, 0); letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div dir="auto" style="letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div dir="auto" style="letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div dir="auto" style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><u style="color: rgb(0, 0, 0);" class=""><b class="">N</b></u>ovel <u style="color: rgb(0, 0, 0);" class=""><b class="">M</b></u>eritorious <u style="color: rgb(0, 0, 0);" class=""><b class="">R</b></u>esearch (and teaching)<br class=""><div style="color: rgb(0, 0, 0);" class=""><div dir="auto" style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div dir="auto" style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div dir="auto" style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div dir="auto" style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div dir="auto" style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div dir="auto" style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div dir="auto" style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div dir="auto" style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""></div></div></div></div></div></div></div></div></div><div style="color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px;"><font color="#0000ba" class="">—•—•—•—•—•—•—•—•—•—•—•—•—•—</font></div><div style="font-variant-caps: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px;"><font color="#0000e1" class=""><font class=""><span style="font-style: normal;" class=""><b class="">A.-F. Miller, Ph. D. </b></span></font></font><b class=""><font color="#0000d2" class=""> (she/elle/sie)</font></b><font color="#0000e1" class=""><font class=""><br class=""></font>University Research Professor<br class=""><font class="">Professor of Chemistry</font></font></div><font color="#0000e1" class="">University of Kentucky</font></div><div dir="auto" style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><font class=""><font color="#0000e1" class=""><a href="https://www.uky.edu/~afm/" class="">https://www.uky.edu/~afm/</a><br class=""></font><br class=""></font></div><div dir="auto" style="color: rgb(0, 0, 0); word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><font color="#db0000" class="">Visiting Fellow, </font></div><div dir="auto" style="color: rgb(0, 0, 0); word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><span style="color: rgb(219, 0, 0);" class=""> Einstein Foundation of Berlin</span></div><div dir="auto" style="color: rgb(0, 0, 0); word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><br class=""></div></div></div></div></div></div></div></div></div></div></div></div></div><br class="Apple-interchange-newline"></div><br class="Apple-interchange-newline"></div><br class="Apple-interchange-newline"></div><br class="Apple-interchange-newline"><br class="Apple-interchange-newline">
</div>
<div><br class=""><blockquote type="cite" class=""><div class="">On Dec 10, 2021, at 5:38 PM, Elaine Meng <<a href="mailto:meng@cgl.ucsf.edu" class="">meng@cgl.ucsf.edu</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div class="">Hi Anne-Frances,<br class="">There is no way to populate the MD plots from a command script, sorry. You would just use the GUI (MD Movie menu: Analysis... Plot), select the two atoms (for a distance) or 3-4 atoms (for an angle) and then it will be plotted across the whole trajectory:<br class=""><<a href="https://www.rbvi.ucsf.edu/chimera/docs/ContributedSoftware/movie/movie.html#plotting" class="">https://www.rbvi.ucsf.edu/chimera/docs/ContributedSoftware/movie/movie.html#plotting</a>><br class=""><br class="">Once you create a distance monitor it is persistent across trajectory frames and will continue to display the updated distance while the trajectory plays. If you really wanted to do it in a per-frame command script and measure distance at each trajectory frame (each value reported in the Reply Log) you could use ~distance command at each frame to remove all the distance monitors after they are added. E.g.<br class=""><br class="">distance :1058@O2 :741@ND1<br class="">distance :730@OH :741@NE2<br class="">distance :721@OG1 :1058@N5<br class="">distance :718@O :1058@N3<br class="">distance :721@N :1058@O4<br class="">distance :722@N :1058@O4<br class="">distance :720@N :1058@O4<br class="">distance :740@O :720@N<br class="">~distance<br class=""><br class="">But then you would need to save Reply Log and process its contents and then put it into some other graphing program if you wanted a plot. This would be a pain since you have lots of different distances. If you want a plot, or even the values in some convenient form for plotting with another program, then probably the way to go is using the GUI from the MD Movie menu.<br class=""><br class="">I hope this helps,<br class="">Elaine<br class="">-----<br class="">Elaine C. Meng, Ph.D. <br class="">UCSF Chimera(X) team<br class="">Department of Pharmaceutical Chemistry<br class="">University of California, San Francisco<br class=""><br class=""><br class=""><br class=""><br class=""><blockquote type="cite" class="">On Dec 10, 2021, at 12:06 AM, Anne-Frances Miller via Chimera-users <<a href="mailto:chimera-users@cgl.ucsf.edu" class="">chimera-users@cgl.ucsf.edu</a>> wrote:<br class=""><br class="">Dear Chimera support,<br class=""><br class="">I want to extract a set of distances and one angle from each snapshot of an MD trajectory (there are 11 of them).<br class="">My plan was to have all my distances appear in one of the MD-movie analysis>plot distances windows and use ‘Dump Values’ to get my numbers out in a way I could use for other plots.<br class="">I realize angles cannot appear in the same plot, but hope I can measure an angle in the same script.<br class=""><br class="">I have a ‘per-frame’ script that runs fine on the first frame, however it returns ‘Problem in per-frame script: Distance monitor already exists’ when I step forward to a second frame.<br class=""><br class="">Nothing appears in a 'MD plots' window (such a window does not open on its own either). <br class="">Reply Log shows the correct distances for the first frame but then only repeats the error after that.<br class="">Problem in per-frame script:<br class="">Distance monitor already exists<br class=""><br class="">My work-flow:<br class="">Open MD/movie, load my trajectory<br class="">open analysis, Per-Frame<br class="">copy my script into the window (chimera commands)<br class="">click ‘apply' in the script window, click ‘play’ or step forward one frame in the MD GUI (looping disabled)<br class=""><br class="">My script:<br class="">~disp<br class="">~ribbon<br class="">disp :718,720,721,722,730,740,741,1058<br class="">distance :1058@O2 :741@ND1<br class="">distance :730@OH :741@NE2<br class="">distance :721@OG1 :1058@N5<br class="">distance :718@O :1058@N3<br class="">distance :721@N :1058@O4<br class="">distance :722@N :1058@O4<br class="">distance :720@N :1058@O4<br class="">distance :740@O :720@N<br class="">angle :1058@C2 :1058@O2 :741@HD1 :741@ND1<br class=""><br class="">Reply Log output:<br class="">Distance between FDM 1058 O2 and HID 741 ND1: 2.8<br class="">Distance between TYR 730 OH and HID 741 NE2: 2.8<br class="">Distance between THR 721 OG1 and FDM 1058 N5: 3.4<br class="">Distance between ILE 718 O and FDM 1058 N3: 3.2<br class="">Distance between THR 721 N and FDM 1058 O4: 2.9<br class="">Distance between GLY 722 N and FDM 1058 O4: 3.2<br class="">Distance between GLN 720 N and FDM 1058 O4: 3.2<br class="">Distance between GLN 740 O and GLN 720 N: 3.0<br class="">Dihedral #0:1058@C2 #0:1058@O2 #0:741@HD1 #0:741@ND1: -51.0515<br class="">Problem in per-frame script:<br class="">Distance monitor already exists<br class=""><br class="">Thank you for any assistance,<br class="">Anne-Frances<br class=""></blockquote><br class=""></div></div></blockquote></div><br class=""></div></body></html>