Re: [Jmol-users] Support of 'alchemy' format for rectangular schematic base-pair geometry

2008-12-10 Thread Robert Hanson
right -- sorry --

 See http://chemapps.stolaf.edu/jmol/docs/examples-11/new.htm and
 http://chemapps.stolaf.edu/jmol/docs/examples-11/Jmol-11.zip


I've put up that roll-bend example instead of the other one.

By the way, one could do a whole lot with quaternions in this area.
Let me know if you are interested in exploring that. Looks like you
might have a prototype for a new cartoon representation of nucleic
acids. What do you think? We could have these for nucleic acids and
planes for proteins. All standard in Jmol.

Bob



 Xiang-Jun

 --
 Xiang-Jun Lu (Ph. D.)
 Creator  Maintainer of 3DNA
 Email: [EMAIL PROTECTED]
 http://3dna.rutgers.edu:8080/forum

 --
 SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada.
 The future of the web can't happen without you.  Join us at MIX09 to help
 pave the way to the Next Web now. Learn more and register at
 http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/
 ___
 Jmol-users mailing list
 Jmol-users@lists.sourceforge.net
 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

--
SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada.
The future of the web can't happen without you.  Join us at MIX09 to help
pave the way to the Next Web now. Learn more and register at
http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/
___
Jmol-users mailing list
Jmol-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jmol-users


Re: [Jmol-users] Support of 'alchemy' format for rectangular schematic base-pair geometry

2008-12-09 Thread Xiang-Jun Lu
 OpenBabel reads the Alchemy format

 http://openbabel.org/wiki/Alchemy

 which makes me wonder if Jmol could use the versatility of Open Babel and
 avoid writing new code.

 Xavier


I have been using 'openbabel' for a long while, and know that it supports
alchemy format. However, it can't read my schematic base-pair geometry. I
know my alchemy file does not have 'proper' chemistry. The chemistry-related
tools are too intelligent to handle such a simple case.

Date: Mon, 08 Dec 2008 23:52:21 +0100
 From:  Angel Herr?ez  [EMAIL PROTECTED]
 Subject: Re: [Jmol-users] Support of 'alchemy' format for rectangular
schematic base-pair geometry
 To: jmol-users@lists.sourceforge.net
 Message-ID: [EMAIL PROTECTED]
 Content-Type: text/plain; charset=US-ASCII

 Xiang, I would suggest that whatever software you use to produce the ALC
 files is changed
 so that it produces MOL files. These have a well documented format
 specification and will
 be read by Jmol as well as RasMol.
 It seems that Alchemy format is rather old (there isn't even a mention of
 the program at the
 Tripos website) and there is no documentation about the format details, so
 it is difficult and
 unlikely that Jmol will read it.


MDL MOL format specifies atoms and bonds as well, and you can easily
 instruct Jmol to
 render those bonds only. I guess you could even use plain text files making
 use of the
 DATA command in Jmol to draw the boxes you need.

  *   As I mentioned in my previous message, I am playing tricks with the
 alchemy format

 Yes, that was clear. But the brief answer is: Jmol does not understand the
 alc format.


  In relation to Jmol, I am hoping Jmol could render such
 non-chemistry-based alchemy file
  properly. In essence, the render just needs to respect the node and
 linkage information explicitly
  defined in the file: it does not try to be clever to deduce some
 chemistry from it.

 Yes, that is perfectly possible. But you need a file format that Jmol
 understands.

 Maybe you can use some utility like OpenBabel to convert ALC to MDL files?
 or http://www.webqc.org/molecularformatsconverter.php



I know alchemy is not as well-supported/documented as the one your
mentioned. I picked alchemy up instead of other options for some random
reason I can't recall. I initially figured out the alchemy format by going
through RasMol code and played with some examples that RasMol writes out. It
is a simple format, and I am using it in the simplest possible way. RasMol
likes it, and I have been using RasMol for interactive visualization purpose
only, without any problem.

As far as Jmol's support for alchemy is concerned, I converted a sample PDB
file to alchemy using 'openbabel' and Jmol can read it without a problem.
That's why I thought Jmol does support standard alchemy in my initial
post, and qualified my subject line with 'alchemy' format  for rectangular
schematic base-pair geometry.

Thanks so much to all of you for for your feedbacks. I still hope Jmol could
support this un-chemical alchemy format. It could be taken as an extreme
case to validate an alchemy reader.

Xiang-Jun

-- 
Xiang-Jun Lu (Ph. D.)
Creator  Maintainer of 3DNA
Email: [EMAIL PROTECTED]
http://3dna.rutgers.edu:8080/forum
--
SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada.
The future of the web can't happen without you.  Join us at MIX09 to help
pave the way to the Next Web now. Learn more and register at
http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/___
Jmol-users mailing list
Jmol-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jmol-users


Re: [Jmol-users] Support of 'alchemy' format for rectangular schematic base-pair geometry

2008-12-09 Thread Robert Hanson
On Tue, Dec 9, 2008 at 10:02 AM, Xiang-Jun Lu [EMAIL PROTECTED] wrote:

 As far as Jmol's support for alchemy is concerned, I converted a sample PDB
 file to alchemy using 'openbabel' and Jmol can read it without a problem.

Can you send me that converted file? I'd like to see what Jmol is doing with it.


-- 
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

--
SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada.
The future of the web can't happen without you.  Join us at MIX09 to help
pave the way to the Next Web now. Learn more and register at
http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/
___
Jmol-users mailing list
Jmol-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jmol-users


Re: [Jmol-users] Support of 'alchemy' format for rectangular schematic base-pair geometry

2008-12-09 Thread Xiang-Jun Lu
Dear Bob,

Thank you so much for your detailed explanations.

Date: Tue, 9 Dec 2008 18:19:09 -0600
 From: Robert Hanson [EMAIL PROTECTED]
 Subject: Re: [Jmol-users] Support of 'alchemy' format for rectangular
schematic base-pair geometry
 To: jmol-users@lists.sourceforge.net
 Message-ID:
[EMAIL PROTECTED]
 Content-Type: text/plain; charset=ISO-8859-1

 Before I write this reader, can I ask if it's possible you could use
 another format?


I could, but I really do not have a solid reason to (see below).

Do you have all these files already made, so you are eager to use them
 exactly, or do you have a program that produces them?


Yes, I have several (utility) programs within 3DNA that produce and read
such alchemy files for various (internal) purposes. It is nice that RasMol
can render them properly, but essentially, 3DNA is a suite of command-line
driven programs which do not rely on RasMol for using the alchemy files.


 Because if it's a program that produces them, I suggest doing a little
 modification to that program to produce Jmol scripts instead. That
 would be far more efficient, and it should be pretty easy to make them
 - probably just one small subroutine. Then you could do all sorts of
 interesting things in relation to dynamically changing them,
 displaying them, measuring them, etc., within Jmol. For example, that
 one you show as a demo could be something like this:

 pt1={-2.2500   5.   0.2500}
 pt2={-2.2500  -5.   0.2500}
 pt3={-2.2500  -5.  -0.2500}
 pt4={-2.2500   5.  -0.2500}
 pt5={2.2500   5.   0.2500}
 pt6={2.2500  -5.   0.2500}
 pt7={2.2500  -5.  -0.2500}
 pt8={2.2500   5.  -0.2500}
 draw box line @pt1 @pt2 @pt3 @pt4 @pt1 @pt5 @pt6 @pt7 @pt8 @pt5
 draw side1 plane @pt1 @pt2 @pt3 @pt4

 (not complete, but you get the idea)

 But even better, you could define a Jmol function that draws the boxes
 for you give the eight points:

 function drawbox(name, pt1, pt2, pt3, pt4, pt5, pt6, pt7, pt8)
  draw ID @{name + _box} line @pt1 @pt2 @pt3 @pt4 @pt1 @pt5 @pt6
 @pt7 @pt8 @pt5
  draw ID @{name + _side1} plane @pt1 @pt2 @pt3 @pt4
  etc.

 end function

 then just

 drawbox({-2.2500   5.   0.2500},{-2.2500  -5.   0.2500}
 ,{-2.2500  -5.  -0.2500} ,\
  {-2.2500   5.  -0.2500},{2.2500   5.   0.2500},{2.2500
 -5.   0.2500},\
  {2.2500  -5.  -0.2500},{2.2500   5.  -0.2500})

 for each box. It seems to me, for that matter, you only need three
 points to define the box. So that would be even easier.

 Now, if you are really fancy, what you do is embed those commands in
 the pdb files themselves, so when the pdb file is loaded, the boxes
 are all drawn automatically. Rolf can show you how he does that at
 Jena.

 And, better, if you are doing this based on some simple criterion in
 PDB files, then you should be able to define a function that allows
 drawing of such boxes for the entire model all within Jmol. That would
 be REALLY COOL, because then anyone could do it with any PDB file. I
 have such a function (somewhere), for example, for drawing all the
 peptide planes.

 Bob


Given the amazing support of Jmol from you and others, I have been
considering to use Jmol (and eventually switch to it), and then came cross
the alchemy format issue. All the cool stuffs you mentioned are very
impressive, and I will surely dig more deeply into Jmol in the future.
However, I still think a simple render of the alchemy format in Jmol would
be ideal. Then people like me could simply load the alchemy file into Jmol
to visualize it without writing any Jmol-specific scripts.

I have checked RasMol v2.6.4 source code, and found the alchemy reader is
via function LoadAlchemyMolecule() in infile.c, and it is pretty short. The
data directory even has an example file 'asprin.alc'.

Since there is no official alchemy document, and given the problem that
'openbabel' has with my non-chemistry oriented alchemy file (see my previous
post), maybe one could forget the complexity of atom/bond types, just take
them as nodes and linkages, and Jmol would render the file at face value.

Thanks,

Xiang-Jun

-- 
Xiang-Jun Lu (Ph. D.)
Creator  Maintainer of 3DNA
Email: [EMAIL PROTECTED]
http://3dna.rutgers.edu:8080/forum
--
SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada.
The future of the web can't happen without you.  Join us at MIX09 to help
pave the way to the Next Web now. Learn more and register at
http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/___
Jmol-users mailing list
Jmol-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jmol-users


Re: [Jmol-users] Support of 'alchemy' format for rectangular schematic base-pair geometry

2008-12-09 Thread Bob Hanson

I'll set it up tonight



On Dec 9, 2008, at 7:21 PM, Xiang-Jun Lu [EMAIL PROTECTED] wrote:


Dear Bob,

Thank you so much for your detailed explanations.

Date: Tue, 9 Dec 2008 18:19:09 -0600
From: Robert Hanson [EMAIL PROTECTED]
Subject: Re: [Jmol-users] Support of 'alchemy' format for rectangular
   schematic base-pair geometry
To: jmol-users@lists.sourceforge.net
Message-ID:
   [EMAIL PROTECTED]
Content-Type: text/plain; charset=ISO-8859-1

Before I write this reader, can I ask if it's possible you could use
another format?

I could, but I really do not have a solid reason to (see below).

Do you have all these files already made, so you are eager to use them
exactly, or do you have a program that produces them?

Yes, I have several (utility) programs within 3DNA that produce and  
read such alchemy files for various (internal) purposes. It is nice  
that RasMol can render them properly, but essentially, 3DNA is a  
suite of command-line driven programs which do not rely on RasMol  
for using the alchemy files.



Because if it's a program that produces them, I suggest doing a little
modification to that program to produce Jmol scripts instead. That
would be far more efficient, and it should be pretty easy to make them
- probably just one small subroutine. Then you could do all sorts of
interesting things in relation to dynamically changing them,
displaying them, measuring them, etc., within Jmol. For example, that
one you show as a demo could be something like this:

pt1={-2.2500   5.   0.2500}
pt2={-2.2500  -5.   0.2500}
pt3={-2.2500  -5.  -0.2500}
pt4={-2.2500   5.  -0.2500}
pt5={2.2500   5.   0.2500}
pt6={2.2500  -5.   0.2500}
pt7={2.2500  -5.  -0.2500}
pt8={2.2500   5.  -0.2500}
draw box line @pt1 @pt2 @pt3 @pt4 @pt1 @pt5 @pt6 @pt7 @pt8 @pt5
draw side1 plane @pt1 @pt2 @pt3 @pt4

(not complete, but you get the idea)

But even better, you could define a Jmol function that draws the boxes
for you give the eight points:

function drawbox(name, pt1, pt2, pt3, pt4, pt5, pt6, pt7, pt8)
 draw ID @{name + _box} line @pt1 @pt2 @pt3 @pt4 @pt1 @pt5 @pt6
@pt7 @pt8 @pt5
 draw ID @{name + _side1} plane @pt1 @pt2 @pt3 @pt4
 etc.

end function

then just

drawbox({-2.2500   5.   0.2500},{-2.2500  -5.   0.2500}
,{-2.2500  -5.  -0.2500} ,\
 {-2.2500   5.  -0.2500},{2.2500   5.   0.2500},{2.2500
-5.   0.2500},\
 {2.2500  -5.  -0.2500},{2.2500   5.  -0.2500})

for each box. It seems to me, for that matter, you only need three
points to define the box. So that would be even easier.

Now, if you are really fancy, what you do is embed those commands in
the pdb files themselves, so when the pdb file is loaded, the boxes
are all drawn automatically. Rolf can show you how he does that at
Jena.

And, better, if you are doing this based on some simple criterion in
PDB files, then you should be able to define a function that allows
drawing of such boxes for the entire model all within Jmol. That would
be REALLY COOL, because then anyone could do it with any PDB file. I
have such a function (somewhere), for example, for drawing all the
peptide planes.

Bob

Given the amazing support of Jmol from you and others, I have been  
considering to use Jmol (and eventually switch to it), and then came  
cross the alchemy format issue. All the cool stuffs you mentioned  
are very impressive, and I will surely dig more deeply into Jmol in  
the future. However, I still think a simple render of the alchemy  
format in Jmol would be ideal. Then people like me could simply load  
the alchemy file into Jmol to visualize it without writing any Jmol- 
specific scripts.


I have checked RasMol v2.6.4 source code, and found the alchemy  
reader is via function LoadAlchemyMolecule() in infile.c, and it is  
pretty short. The data directory even has an example file  
'asprin.alc'.


Since there is no official alchemy document, and given the problem  
that 'openbabel' has with my non-chemistry oriented alchemy file  
(see my previous post), maybe one could forget the complexity of  
atom/bond types, just take them as nodes and linkages, and Jmol  
would render the file at face value.


Thanks,

Xiang-Jun

--
Xiang-Jun Lu (Ph. D.)
Creator  Maintainer of 3DNA
Email: [EMAIL PROTECTED]
http://3dna.rutgers.edu:8080/forum
--- 
--- 
--- 
-
SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas,  
Nevada.
The future of the web can't happen without you.  Join us at MIX09 to  
help

pave the way to the Next Web now. Learn more and register at
http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/
___
Jmol-users mailing list
Jmol-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jmol-users
--
SF.Net email is Sponsored by MIX09, March 18-20, 2009

Re: [Jmol-users] Support of 'alchemy' format for rectangular schematic base-pair geometry

2008-12-08 Thread Rolf Huehne
Xiang-Jun Lu wrote:
 Hi,
 
 Over the years, I have been using RasMol 2.6.4 (from Roger Sayle) for
 interactive rendering of a 3DNA-specific rectangular schematic
 representation of base and base-pair geometry. As an example image, please
 see:
 http://rutchem.rutgers.edu/~xiangjun/3DNA/jmol/3dna_bp-rasmol2-6-4.png
 
 Recently, I am considering to use Jmol as well, given the great support of
 the Jmol community (as is evident from this list). While Jmol recognizes a
 regular alchemy format file without a problem, it does not render my
 schematic alchemy file as expected (e.g.,
 http://rutchem.rutgers.edu/~xiangjun/3DNA/jmol/3dna_bp.alc): a sample image
 is shown at: http://rutchem.rutgers.edu/~xiangjun/3DNA/jmol/3dna_bp-jmol.png
 
 Essentially, I am playing tricks with the alchemy format purely as a
 rendering tool by specifying explicitly each node and linkage, no chemistry
 at all. Hopefully, Jmol would be able to render it as well, just as RasMol
 does.
 
I don't know anything about the alchemy format. But I did a similar
thing in PDB format to design the Logo of our Jena3D viewer:

http://jena3d.fli-leibniz.de/doc/examples/Jena3D_Logo.pdb

And this works perfectly with Jmol:

http://www.imb-jena.de/cgi-bin/3d_mapping.pl?UPLOAD_DATA=MODE=uploadSCRIPT=/Jena3D/examples/Jena3D_Logo-animated.jmz

So maybe you could switch to PDB format if alchemy format doesn't work
for you.

Regards,
Rolf

--
SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada.
The future of the web can't happen without you.  Join us at MIX09 to help
pave the way to the Next Web now. Learn more and register at
http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/
___
Jmol-users mailing list
Jmol-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jmol-users