Yes, sorry, the frames are mapped to states. Ah, yes, that is what I needed, that 'state' keyword argument was not listed in the wiki page.
For posterity's sake, a couple of minor modifications were required in the code you provided. python for i in range(1,41): cmd.select("wat_" + str(i),"resn WAT in <mdobjetct> within 6 of <residue_of_interest>", state=i) python end I removed the byres command because I have more then 10000 water molecules in my system and the residue ID's were rolling over and waters far from the residue of interest were being selected. If anyone has a suggestion on this, please let me know, I would like to select whole water molecules for making figures. Thanks, Matt On 07/01/2013 02:10 PM, Jordan Willis wrote: > I know you have asked for frames, but I assume that each frame is mapped to a > state. The selection logic allows for you to specify the state. > > So if the waters of interest are in state 1,40: > > python > for i in range(1,41): > cmd.select("wat_"+i,"byres in <mdobjetct> within 6 of > <residue_of_interest>",state=i) > python end > > J > > >> 'sele wats, byres res >> WAT in <md_obj> within 6 of >> <residue of interest>', > > > On Jul 1, 2013, at 12:42 PM, Matthew Baumgartner <mp...@pitt.edu> wrote: > >> Hi, >> Is it possible to force a selection to only apply to the specific frame >> rather then across frames? >> I'm running in to a problem where I have some (~40) frames from an >> explicit solvent MD that I want to look at. What I want to do is look at >> water molecules around a specific residue at each frame, but when I do >> something like, 'sele wats, byres resn WAT in <md_obj> within 6 of >> <residue of interest>', it ends up a majority of the waters in the >> system. I think that what it is doing is finding all waters that are >> with 6 A of the residue of interest in ALL frames, then selecting them >> in the current frame. Which is not the expected behavior. >> >> From what I can tell, there isn't a selection syntax for selecting the >> frame. Perhaps there is a setting for this that I couldn't find. >> >> Any help would be appreciated including solutions involving VMD or >> custom scripts. >> >> Thanks, >> Matt >> >> -- >> >> >> ------------------------------------------------------------------------------ >> This SF.net email is sponsored by Windows: >> >> Build for Windows Store. >> >> http://p.sf.net/sfu/windows-dev2dev >> _______________________________________________ >> PyMOL-users mailing list (PyMOL-users@lists.sourceforge.net) >> Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users >> Archives: http://www.mail-archive.com/pymol-users@lists.sourceforge.net ------------------------------------------------------------------------------ This SF.net email is sponsored by Windows: Build for Windows Store. http://p.sf.net/sfu/windows-dev2dev _______________________________________________ PyMOL-users mailing list (PyMOL-users@lists.sourceforge.net) Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users Archives: http://www.mail-archive.com/pymol-users@lists.sourceforge.net