almost. This of course depends upon the file format. But for auxiliaryInfo
the individual model data are under the vector "models" because there is
also auxiliaryInfo for the model set as a whole as well. {1.3} means the
third model of the first file, but that still returns a vector of models of
length 1.

var Energy = jmolEvaluate('getProperty("auxiliaryInfo.models[1].zeroPoint",
{1.3})', 1)

(I think)

On Sun, Aug 31, 2008 at 12:34 PM, Jeff Hansen <[EMAIL PROTECTED]> wrote:

> So for example, could I use the following to get the zero point energy from
> the third model in the first file loaded into the second applet of several
> applets on a page?
> var Energy = jmolEvaluate('getProperty("auxiliaryInfo.zeroPoint", {1.3},
> 1)')
>
> ***********************************************
> Jeff Hansen
> Department of Chemistry and Biochemistry
> DePauw University
> 602 S. College Ave.
> Greencastle, IN 46135
> [EMAIL PROTECTED]
> ***********************************************
>
>
> On Aug 30, 2008, at 11:45 PM, Robert Hanson wrote:
>
> getProperty can be a very inefficient function. The algorithm is designed
> to return the entire property set, then do the selections. So, for example,
> if you say:
>
>   print getProperty("atomInfo[3]")
>
> and there are 30000 atoms, then first a vector containing 30000 elements is
> produced and only after that is one selected.
>
> I'm reminded that I thought of that and had a solution to it but forgot.
> The alternative format:
>
>   print getProperty("atomInfo", {atomIndex=3})
>
> is far more efficient, as it only creates a single atomInfo entry -- an
> array with one element.
>
> I've checked in code now that combines these:
>
>   print getProperty("atominfo[1].sym", {atomIndex=3})
>
> creates only one entry and then selects the information about atom symbol
> from that single entry. ([0] would work as well, because that means "the
> last entry", and there is only one)
>
> In checking through the code, I also noticed that "bondInfo" works
> similarly, but both atoms of the bond must be selected. I've now changed
> that so that if you specify just one atom, then "bondInfo" gives you what
> you think it would -- the bond info for that atom:
>
>   print getProperty("bondInfo", {atomno=2})
>
> [[ information about all bonds to atom #2 are displayed ]]
>
> Similarly,
>
>   print getProperty("bondInfo[1]", {atomno=2})
>
> give information about just the first bond to atom #2.
>
> In addition, getProperty("modelInfo") was not allowing an atom expression,
> but it seems to me that would make sense as well:
>
>   print getProperty("modelInfo", {atomIndex=2})
>
> or perhaps
>
>   print getProperty("modelInfo", {1.3})
>
> So I have added that.
>
> Finally, getProperty("auxiliaryInfo") also could allow for specifying the
> model, so I have added that as well:
>
>   print getProperty("auxiliaryInfo", {1.3})
>
>
> These changes should make for much more efficient extraction of
> information.
>
> Bob
> --
> Robert M. Hanson
> Professor of Chemistry
> St. Olaf College
> Northfield, MN
> http://www.stolaf.edu/people/hansonr
>
>
> If nature does not answer first what we want,
> it is better to take what answer we get.
>
> -- Josiah Willard Gibbs, Lecture XXX, Monday, February 5, 1900
>  -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's
> challenge
> Build the coolest Linux based applications with Moblin SDK & win great
> prizes
> Grand prize is a trip for two to an Open Source event anywhere in the world
>
> http://moblin-contest.org/redirect.php?banner_id=100&url=/_______________________________________________
> Jmol-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/jmol-users
>
>
>
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's
> challenge
> Build the coolest Linux based applications with Moblin SDK & win great
> prizes
> Grand prize is a trip for two to an Open Source event anywhere in the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> Jmol-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/jmol-users
>
>


-- 
Robert M. Hanson
Professor of Chemistry
St. Olaf College
Northfield, MN
http://www.stolaf.edu/people/hansonr


If nature does not answer first what we want,
it is better to take what answer we get.

-- Josiah Willard Gibbs, Lecture XXX, Monday, February 5, 1900
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Jmol-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jmol-users

Reply via email to