Feature Requests item #1830586, was opened at 2007-11-12 12:21
Message generated for change (Comment added) made by hansonr
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=379136&aid=1830586&group_id=23629
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
>Status: Closed
Priority: 5
Private: No
Submitted By: Rolf Huehne (rhuehne)
Assigned to: Bob Hanson (hansonr)
Summary: show boundbox on structure part
Initial Comment:
The "show boundbox" command is quite useful for scripting purposes.
But there are many PDB files, especially of biological units from the PDB that
contain a lot of rather uninteresting water molecules (e.g. 4otb.pdb1; in the
case of a reduction compared to the asymmetric unit usually all water molecules
remain in the first biological unit file) that disturb the boundbox information.
Therefore it would be very useful to be able to provide an atom expression to
restrict the boundbox:
show boundbox (atom_expression)
----------------------------------------------------------------------
>Comment By: Bob Hanson (hansonr)
Date: 2007-12-30 16:15
Message:
Logged In: YES
user_id=1082841
Originator: NO
1.3.45 command is
boundbox (atom_expression)
"show" is reserved for information only; added along with the above is:
var x = {atom_expression}.boundbox
or
print {atom_expression}.boundbox
etc.
----------------------------------------------------------------------
Comment By: Bob Hanson (hansonr)
Date: 2007-11-19 08:14
Message:
Logged In: YES
user_id=1082841
Originator: NO
basically I recommend not using show boundbox for any serious calculation.
The recommendation is to use the new
x = getProperty("boundboxInfo")
x = getProperty("boundboxInfo","vector")
x = getProperty("boundboxInfo","center")
x = getProperty("boundboxInfo","corner0")
x = getProperty("boundboxInfo","corner1")
capability
----------------------------------------------------------------------
Comment By: Bob Hanson (hansonr)
Date: 2007-11-13 13:23
Message:
Logged In: YES
user_id=1082841
Originator: NO
OK, here's the proper solution to this. Rather than using show boundbox to
extract information, we should be using Jmol math. I have now integrated
the getProperty command into Jmol math, allowing for all the information in
getProperty to be available as user variables:
version=11.3.44_dev
# new feature: Jmol math getProperty() function
# allows FULL math access to ALL getProperty types
#
# syntax: getProperty(propertyType,{atomset}, itemSelector,
propertyName1, propertyName2)
#
# examples:
#
# print getProperty("modelInfo")
# print getProperty("boundboxInfo")
# print getProperty("boundboxInfo", "center")
# print getProperty("boundboxInfo", "vector")
# print getProperty("atomInfo",{atomno=3})
# print getproperty("bondInfo",{*},2,"atom1")
# print getproperty("bondInfo",{*},2,"atom1", "sym")
# print getProperty("") # displays list of possibilities
#
# {atomset} is required if itemSelector is given
# itemSelector is optional; if omitted, 0 assumed
# propertyName1 is optional;
# propertyName2 is optional;
#
# This is preliminary -- may adjust parameterization as needed
----------------------------------------------------------------------
Comment By: Rolf Huehne (rhuehne)
Date: 2007-11-13 10:43
Message:
Logged In: YES
user_id=1344570
Originator: YES
Sorry that I was not clear enough, but I thought it was obvious because
the "show boundbox" command didn't influence the display of the boundbox.
The braces are no problem. The missing commas even simplified the
parsing:
bound_box = script("show
boundbox").replace("{","").replace("}","").split(" ");
vector_x = bound_box[5];
vector_y = bound_box[6];
vector_z = bound_box[7];
----------------------------------------------------------------------
Comment By: Bob Hanson (hansonr)
Date: 2007-11-13 06:32
Message:
Logged In: YES
user_id=1082841
Originator: NO
Ah! I misunderstood! You just wanted to be able to calculate the bounding
box, but I actually made it so you could SEE the bounding box for a
specific atom expression. In addition, I added
boundbox {bottom corner} {top corner}
I changed the output of show boundbox to be, like draw, consistent with
the new command, so one could clip that and use it if one wanted to -- a
legitimate command. The other option was to implement
boundbox {center} {center to corner}
but that seemed odd to me, since, for example, in EPS the bounding box is
not defined this way.
I'll change it back, but the { } will need to stay, not () around those
numbers, OK?
----------------------------------------------------------------------
Comment By: Rolf Huehne (rhuehne)
Date: 2007-11-13 05:42
Message:
Logged In: YES
user_id=1344570
Originator: YES
Hi Bob,
thanks for implementing this immediately.
But unfortunately you also changed the output of "show boundbox".
What I am really interested in are only vectorX, vectorY and vectorZ which
are not available any more. Although it seems possible to obtain it from
the corner coordinates it is far more complicated with Jmol scripting (my
script has to work in the application and the applet).
Besides the "center point + vectorX/Y/Z" information immediately revealed
the geometry of the boundbox while now you have to do several calculations
to obtain this information. And others might also use the "show boundbox"
output for scripting and won't like this (unnecessary) change.
So why do you want to change the output (besides adding the volume)?
----------------------------------------------------------------------
Comment By: Bob Hanson (hansonr)
Date: 2007-11-12 21:50
Message:
Logged In: YES
user_id=1082841
Originator: NO
Fabulous idea.
version=11.3.44_dev
# new feature: boundbox {atomExpression} [on|off]
# sets the bound box around the specified atom expression
# default ON/OFF is to NOT change current setting
# new feature: boundbox {centerExpression} {centerExpression} [on|off]
# sets the bound box to encompass the two center points
# strangely enough this allows setting the boundbox to a 2D or 1D box
# new feature: show boundbox gives two corner points and volume
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=379136&aid=1830586&group_id=23629
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Jmol-developers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jmol-developers