MOLEC Function
Standard Library function that creates an image of a ball and stick molecular model.
Usage
result = MOLEC(filename)
Input Parameters
filename—The name of an ASCII file describing the molecular model. Line 1 in the file consists of a single integer designating the number (m) of atoms. Each of the lines 2 – (m+1) contains 7 floats describing an atom in terms of centroid, normalized RGB color components, and diameter. Line m+2 consists of a single integer equal to the number (n) of bonds; each of the lines (m+3)-(m+n+2) contains 6 floats describing a bond as endpoint1 followed by endpoint2.
Returned Value
result—A 24-bit image of the molecular model.
Keywords
h—A scale factor for adjusting atom size. The default is h=1.0.
s—A 2-element vector specifying image size. The default is s=[500,500].
v—A 3-by-4 double-precision floating-point array used to override the autogeneration of the view to that specified as: [viewpoint, top_left_viewplane, bottom_left_viewplane, bottom_right_viewplane]. v and !P.T control the 3D view.
k—(output) A 3-by-4 double-precision floating-point array used to return the automatically calculated view as: [viewpoint, top_left_viewplane, bottom_left_viewplane, bottom_right_viewplane].
Examples
T3D, /Reset
TV, MOLEC(!Data_dir + 'molec.dat', h=0.6), True=3
Version 2017.0
Copyright © 2017, Rogue Wave Software, Inc. All Rights Reserved.