<div dir="ltr">Hi Eric,<div><br></div><div>Thank you for your reply. I am understanding that the castp python script works only for .pdb files. But it would be really time consuming for me to upload each of the .pdb1 file to castp and then download the .poc and .pocInfo files as I have to process these two files again to extract the atoms list, pocID and MS_volume values.</div>
<div><br></div><div>Could you please elaborate more on how to extract the .poc and .pocInfo values for .pdb1 files from CASTp server using <span style="font-family:arial,sans-serif;font-size:13px">processCastpID() and </span><span style="font-family:arial,sans-serif;font-size:13px">processCastpFiles(). I need to be able to loop through all .pdb1 files and for each pdb1 file I need to get the atoms list for each pocID along with pocVolumes and to write these values into a .csv file.</span></div>
<div><span style="font-family:arial,sans-serif;font-size:13px"><br></span></div><div><span style="font-family:arial,sans-serif;font-size:13px">Thank you in advance,</span></div><div><span style="font-family:arial,sans-serif;font-size:13px">Navya</span></div>
</div><div class="gmail_extra"><br><br><div class="gmail_quote">On Thu, Apr 17, 2014 at 5:05 PM, Eric Pettersen <span dir="ltr"><<a href="mailto:pett@cgl.ucsf.edu" target="_blank">pett@cgl.ucsf.edu</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word"><div><div class=""><div>On Apr 17, 2014, at 2:11 PM, Navya Shilpa Josyula <<a href="mailto:njosyu2@uic.edu" target="_blank">njosyu2@uic.edu</a>> wrote:</div>
<br><blockquote type="cite"><div style="font-family:Helvetica;font-size:medium;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:-webkit-auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px">
Now I am trying to write CASTp information for each of my proteins into a separate file. As you suggested in earlier email, the processCastpID function is in the gui.py file but not in __init__.py file. Hope I am not missing anything here. As per my understanding, this function is fetching the 4 castp files of which I would require only ".poc" and ".pocInfo" files. From these two files I want to write the data of only atoms list, pocID and MS_Volume data into a single file for all 400 proteins in my dataset. Is there a link or any script available for such requirement?</div>
</blockquote><div><br></div></div>There are some fine points that I missed in my answer yesterday, and the situation is complicated further by your use of .pdb1 files instead of the "normal" entries.</div><div>
<br>
</div><div>So for one thing, if you are going to use the .pdb1 files, then you are going to have to run CASTp yourself on each and then process the results. In that case you might as well also analyze the .poc and .pocInfo files yourself to determine what pocket each atom belongs to (the next-to-last field in the .poc file) and the volume of that pocket (listed in the .pocInfo file).</div>
<div><br></div><div>The main point I missed in my reply, which may now be moot because of the .pdb1 thing, is that processCastpID() builds its own structure and therefore you would not open the PDB first, you would instead return the structure (along with the cavities list) from that method and make the structure available in chimera with:</div>
<div><br></div><div><span style="white-space:pre-wrap"> </span>chimera.openModels.add([structure])</div><div><br></div><div>and then proceed with selecting the right residues, using currentResidues() to list them, etc. I guess if you didn't want to process the .pdb1 CASTp files yourself (after running CASTp on the .pdb1) you could use processCastpFiles() to get the cavity list and structure and proceed as I just outlined. processCastpFiles <i>is</i> in __init__, unlike processCastpID() as you found!</div>
<div class=""><div><br><blockquote type="cite"><div style="font-family:Helvetica;font-size:medium;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:-webkit-auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px">
Again, as mentioned in my last email, since my output files will be huge in size, will I be able to write my files directly to a database table in SQL server?</div></blockquote><br></div></div><div>I'm not much of an expert on this, but maybe this page would help: <a href="https://wiki.python.org/moin/DatabaseInterfaces" target="_blank">DatabaseInterfaces - Python Wiki</a></div>
<span class="HOEnZb"><font color="#888888"><div><br></div><div>--Eric</div><div><br></div><br></font></span></div></blockquote></div><br></div>