VMD-L Mailing List
From: Brian Kim (bnk25_at_cornell.edu)
Date: Tue Feb 07 2012 - 19:11:27 CST
- Next message: Axel Kohlmeyer: "Re: charge visualization"
- Previous message: niladri patra: "charge visualization"
- Maybe in reply to: Axel Kohlmeyer: "Re: Use variable in atomselect command"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Hi Jacky,
Fantastic! Thank you, it works.
Brian
On Tue, Feb 7, 2012 at 7:39 PM, Kei Sit <kei.sit_at_qut.edu.au> wrote:
> Hi Brian,****
>
> ** **
>
> I think I’ve worked out how to do this. Write your command like this:****
>
> ** **
>
> set sel1 [atomselect [molinfo top] “PO4 and resname PPCS and z < ${zmass}”]
> ****
>
> ** **
>
> That command should work, I tested it out with my own commands and it
> seemed to work fine.****
>
> ** **
>
> Hope that helps!****
>
> Regards,****
>
> Jacky****
>
> ** **
>
> *From:* owner-vmd-l_at_ks.uiuc.edu [mailto:owner-vmd-l_at_ks.uiuc.edu] *On
> Behalf Of *Brian Kim
> *Sent:* Wednesday, 8 February 2012 8:40 AM
> *To:* Axel Kohlmeyer
> *Cc:* vmd-l_at_ks.uiuc.edu
> *Subject:* Re: vmd-l: Use variable in atomselect command****
>
> ** **
>
> Hi,****
>
> ** **
>
> Thank you for the reply. I guess I wasn't clear in my original message. **
> **
>
> The membrane is formed with Cholesterol and many different lipid types
> including PPCS.****
>
> I use CHOL headgroup (ROH) and headgroups of other lipids (PO4) to
> calculate the COM of the membrane.****
>
> ** **
>
> Then, I count each and every type of lipids on each leaflet of membrane.**
> **
>
> ** **
>
> set sel1 [atomselect [molinfo top] {name PO4 and resname PPCS and z
> < $zmass}]****
>
> ** **
>
> is one example of atomselect to count how many PPCS are found in lower
> leaflet of membrane.****
>
> In order to do that, my next line would be ****
>
> ** **
>
> $sel num****
>
> ** **
>
> My question is if "z < $zmass" is a correct term that can be used in
> atomselect. If I put a certain number like 100 instead of $zmass, this line
> works fine. But with $zmass, it doesn't.****
>
> ** **
>
> Thank you,****
>
> ** **
>
> Brian****
>
> ** **
>
> ****
>
> ** **
>
> ** **
>
> ** **
>
> On Tue, Feb 7, 2012 at 5:15 PM, Axel Kohlmeyer <akohlmey_at_gmail.com> wrote:
> ****
>
> On Tue, Feb 7, 2012 at 4:16 PM, Brian Kim <bnk25_at_cornell.edu> wrote:
> > Hi all,
> >
> > I am sort of new to this vmd and tcl script so forgive me if this
> question
> > is way too easy for this mailing list.
> >
> > I am trying to use atomselect with a variable in lipid bilayer
> simulation.
> > The center of mass for membrane that I produced is changing over time
> and I
> > would like to count how many lipids are on each leaflet of membrane in
> every
> > frame of the simulation by comparing their z location to z coordinate of
> > COM.
> >
> > For example,
> >
> > # calculate z coordinate of COM
> > set COM [atomselect [molinfo top] {name ROH or name PO4}]
> > set x [measure center $COM]
> > foreach {xmass ymass zmass} $x { break }
> >
> > # atomselect PPCS lipids that is located below zmass.
> > set sel1 [atomselect [molinfo top] {name PO4 and resname PPCS and z <
> > $zmass}]
> >
> >
> >
> > However, it doesn't work. It's always 0 even though zmass is correct in
> each
> > frame.****
>
> best you check your selection string manually using two representations.
>
> you know that you use two different selection strings for compute
> "zmass" and to compare against it. also the logic is different (logical
> "or" and logical "and")
>
> how should that work?
>
> axel.****
>
>
> >
> > Can anyone give me some help? Thank you very much in advance!
> >
> > regards,
> >
> > Brian
> >
> > --
> > Brian N. Kim
> > Ph.D Candidate
> > Graduate Field of Biophysics
> > Cornell University, Ithaca, NY 14853
> > Phone: 607 - 255 - 0632
>
>
> ****
>
> --
> Dr. Axel Kohlmeyer
> akohlmey_at_gmail.com http://goo.gl/1wk0
>
> College of Science and Technology
> Temple University, Philadelphia PA, USA.****
>
>
>
> ****
>
> ** **
>
> --
> Brian N. Kim
> Ph.D Candidate
> Graduate Field of Biophysics
> Cornell University, Ithaca, NY 14853
> Phone: 607 - 255 - 0632****
>
-- Brian N. Kim Ph.D Candidate Graduate Field of Biophysics Cornell University, Ithaca, NY 14853 Phone: 607 - 255 - 0632
- Next message: Axel Kohlmeyer: "Re: charge visualization"
- Previous message: niladri patra: "charge visualization"
- Maybe in reply to: Axel Kohlmeyer: "Re: Use variable in atomselect command"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]