animateHive | R Documentation |
This function takes a list of HivePlotData
objects of type =
"3D"
and plots each in its own rgl
window using its own arguments,
then adds a controller which handles rotation and scaling.
animateHive(hives = list(), cmds = list(), xy = 400, ...)
hives |
A list of |
cmds |
A list of arguments corresponding to how you want each hive plotted. |
xy |
An integer giving the size of the |
... |
Other parameters to be passed downstream to |
None. Side effect is one or more plots.
If you click the 'continue rotating' box on the controller window, be sure to unclick it and wait for the system to halt before closing any of the windows. If you close the controller w/o doing this, the remaining open windows with the hive plots will continue rotating endlessly and it seems you can't get their attention to close the windows.
Bryan A. Hanson, DePauw University. hanson@depauw.edu
## Not run:
require("rgl")
# Sillyness: let's draw different hives with different settings
# List of hives
t4 <- ranHiveData(type = "3D", nx = 4)
t5 <- ranHiveData(type = "3D", nx = 5)
t6 <- ranHiveData(type = "3D", nx = 6)
myhives <- list(t4, t5, t6)
# List of arguments to plot in different coordinate systems
cmd1 <- list(method = "abs", LA = TRUE, dr.nodes = FALSE, ch = 10)
cmd2 <- list(method = "rank", LA = TRUE, dr.nodes = FALSE, ch = 2)
cmd3 <- list(method = "norm", LA = TRUE, dr.nodes = FALSE, ch = 0.1)
mycmds <- list(cmd1, cmd2, cmd3)
#
animateHive(hives = myhives, cmds = mycmds)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.