| viewAxis {Rpdb} | R Documentation |
Set the View of the ‘rgl’ Scene
Description
Set the view of the current ‘rgl’ scene aligning one vector perpendicularly to the screen and placing another one in the horizontal plane.
Usage
viewAxis(V1, V2)
viewXY()
viewYZ()
viewZX()
viewAB(cryst1)
viewBC(cryst1)
viewCA(cryst1)
viewInertia(x, m = NULL)
Arguments
V1 |
a length 3 numeric vector. |
V2 |
a length 3 numeric vector. |
cryst1 |
an object of class ‘cryst1’. |
x |
an R object containing atomic coordinates. |
m |
a numeric vector containing atomic masses. |
Details
viewAxis set the view of the current rgl scene (by setting
UserMatrix; see par3d for more details) so that
V1 is perpendicular to the screen and V2 is in the horizontal
plane. The other functions documented here are helper functions calling
viewAxis to set the view using particular Cartesian or lattice
vectors. For functions viewAB, viewBC and viewCA a
‘cryst1’ object has to be specifyed to define the lattice vectors
used to set the view. The function viewInertia computes the inertia
tensor from the atomic coordinates and masses (see inertia)
and sets the view to its eigen vectors basis set.
Value
No return value, called for side effects.
See Also
visualize, cell.coords, par3d, rgl.open
Examples
x <- read.pdb(system.file("examples/PCBM_ODCB.pdb", package="Rpdb"))
visualize(x, mode = NULL)
viewAB(x$cryst1)
C70 <- read.pdb(system.file("examples/C70.pdb", package="Rpdb"))
visualize(C70, mode = NULL)
viewXY()
viewInertia(C70)