I'm loading it to a large number of NMR models, so was trying to have it
load once. I didn't see the sense in having the applet part of the script
repeated 14 times. 

 

 I wasn't sure if there was a performance issue loading the script multiple
times. I know from yesterday there isn't when you're using MODELS from the
pdb since it's cached, but not sure about how a script was handled.

 

From: Robert Hanson [mailto:[email protected]] 
Sent: Friday, December 04, 2009 11:55 AM
To: [email protected]
Subject: Re: [Jmol-users] running a rasmol script

 

you are sending the jmolScript command before you have the applet set up. If
all you are doing is sending the same startup script to the two applets,
just do it as I have modified below:

On Fri, Dec 4, 2009 at 10:51 AM, Brian Moldover <[email protected]> wrote:

Getting the error message: could not find applet jmolApplet0

Here is the code:
<head> 
  <title>Multiple load models from pdb</title> 
  <script type="text/javascript" src="jmol/Jmol.js" ></script> 
</head> 
<body>

<script type="text/javascript">
      jmolInitialize("jmol");       
</script>

    <script type="text/javascript"> 
      jmolApplet(200, "load MODELS ({0}) jmol/pdb1as5.pdb;script
jmol/Gcolors.txt", "1");  
    </script>
 
    <script type="text/javascript"> 
      jmolApplet(200, "load MODELS ({1}) jmol/pdb1as5.pdb;script
jmol/Gcolors.txt", "2");  
    </script>

 

On Fri, Dec 4, 2009 at 11:26 AM, Brian Moldover <[email protected]> wrote:

Thanks, could not find the right example for jmolscript. Was struggling with
trying to use jmolscript(script "filename", "all") which obviously is
incorrect!

 

From: Robert Hanson [mailto:[email protected]] 
Sent: Friday, December 04, 2009 11:21 AM
To: [email protected]
Subject: Re: [Jmol-users] running a rasmol script

 

within Jmol:

script APPLET * "background red"

applies the script to all applets. So from JavaScript:

jmolScript('script APPLET * "background red" ')

or, if this is in a file:

jmolScript('script APPLET * "script myfile.spt" ')

or if you need quotes for that filename....

jmolScript('script APPLET * \'script "myfile.spt" \' ')

On Fri, Dec 4, 2009 at 10:07 AM, Brian Moldover <[email protected]> wrote:

Hi all,

 

Is there a way to load a long rasmol-type script so that it can be applied
to multiple applets? I have a number of atom colorations for each model, and
in the script I use restrict */n and then the atom colors, cycling  (n)
through each model. I'm using jmolapplet("load MODELS ({}) "filename.pdb").

 

-          Brian  


----------------------------------------------------------------------------
--
Join us December 9, 2009 for the Red Hat Virtual Experience,
a free event focused on virtualization and cloud computing.
Attend in-depth sessions from your desk. Your couch. Anywhere.
http://p.sf.net/sfu/redhat-sfdev2dev
_______________________________________________
Jmol-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jmol-users




-- 
Robert M. Hanson
Professor of Chemistry
St. Olaf College
1520 St. Olaf Ave.
Northfield, MN 55057
http://www.stolaf.edu/people/hansonr
phone: 507-786-3107


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

Internal Virus Database is out of date.
Checked by AVG - www.avg.com
Version: 8.5.238 / Virus Database: 270.14.84/2530 - Release Date: 11/27/09
07:58:00

 


----------------------------------------------------------------------------
--
Join us December 9, 2009 for the Red Hat Virtual Experience,
a free event focused on virtualization and cloud computing.
Attend in-depth sessions from your desk. Your couch. Anywhere.
http://p.sf.net/sfu/redhat-sfdev2dev
_______________________________________________
Jmol-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jmol-users




-- 
Robert M. Hanson
Professor of Chemistry
St. Olaf College
1520 St. Olaf Ave.
Northfield, MN 55057
http://www.stolaf.edu/people/hansonr
phone: 507-786-3107


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

Internal Virus Database is out of date.
Checked by AVG - www.avg.com
Version: 8.5.238 / Virus Database: 270.14.84/2530 - Release Date: 11/27/09
07:58:00

------------------------------------------------------------------------------
Join us December 9, 2009 for the Red Hat Virtual Experience,
a free event focused on virtualization and cloud computing. 
Attend in-depth sessions from your desk. Your couch. Anywhere.
http://p.sf.net/sfu/redhat-sfdev2dev
_______________________________________________
Jmol-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jmol-users

Reply via email to