# NOT RUN {
if (interactive()) {
g <- ggobi(mtcars)
d <- displays(g)[[1]]
}
# }
# NOT RUN {
pmode(d) <- "2D Tour"
variables(d) <- list(X=names(mtcars))
ggobi_display_get_tour_projection(d)
pc <- princomp(as.matrix(mtcars))$loadings[,1:2]
ggobi_display_set_tour_projection(d, pc)
pc <- princomp(as.matrix(mtcars), cor=T)$loadings
ggobi_display_set_tour_projection(d, pc)[,1:2]
# }
Run the code above in your browser using DataLab