Moving slices in 3D {OceanView} | R Documentation |
Plotting volumetric data as moving slices in 3D using rgl
Description
movieslice3D
plots 3D volumetric data as slices moving in one direction
in open-GL graphics.
It is based on the plot3Drgl
function slice3Drgl.
Usage
movieslice3D (x, y, z, colvar = NULL, xs = NULL,
ys = NULL, zs = NULL, along = NULL,
col = jet.col(100), NAcol = "white", breaks = NULL,
colkey = FALSE, clim = NULL, clab = NULL,
wait = NULL, ask = FALSE, add = FALSE, basename = NULL, ...)
Arguments
x , y , z |
Vectors with x, y and z-values.
They should be of length equal to the first, second and
third dimension of |
colvar |
The variable used for coloring.
It should be an array of dimension equal to
|
col |
Colors to be used for coloring the |
NAcol |
Colors to be used for |
breaks |
a set of finite numeric breakpoints for the colors; must have one more breakpoint than color and be in increasing order. Unsorted vectors will be sorted, with a warning. |
colkey |
A logical, |
clim |
Only if |
clab |
Only if |
xs , ys , zs |
Vectors specify the positions in x, y or z where the slices (planes) are to be drawn consecutively.
The movie will loop over the slices, each time projecting the values of |
along |
A number 1, 2, 3 denoting the dimension over which the slices are to be moved.
If |
add |
Logical. If |
ask |
Logical. If |
wait |
The time interval inbetween drawing of a new slice, in seconds.
If |
basename |
The base name of a |
... |
additional arguments passed to slice3D from package
|
Value
returns nothing
Author(s)
Karline Soetaert <karline.soetaert@nioz.nl>
See Also
Sylt3D for a data set that can be displayed with movieslice3D
moviepoints3D for plotting moving points in 3D
Examples
x <- y <- z <- seq(-1, 1, by = 0.1)
grid <- mesh(x, y, z)
colvar <- with(grid, x*exp(-x^2 - y^2 - z^2))
movieslice3D (x, y, z, colvar = colvar, ticktype = "detailed")