Usage example

knitr::opts_chunk$set(
  collapse = TRUE,
  comment = "#>"
)

As an example we will use measurements of penguins made at Palmer Station, Antarctica.

Since the measurements are in different units, we supply an appropriate scaling.

library(langevitour)
library(palmerpenguins)

completePenguins <- na.omit(penguins[,c(1,3,4,5,6)])
completePenguins

scale <- apply(completePenguins[,-1], 2, sd)*4

langevitour(
    completePenguins[,-1], completePenguins$species, 
    scale=scale, pointSize=2, elementId="myWidget")


Things to try:

Drag labels onto the plot.
Turn on a guide.
Experiment with "damping" and "heat" in the hamburger menu.
When only three measurements are shown, your eyes will interpret the display as 3D. Hide measurements by unchecking the checkbox on their label.

Further examples

Some further examples have been omitted from the CRAN package due to their large size and problematic dependencies. They can be viewed on the langevitour website:



Try the langevitour package in your browser

Any scripts or data that you put into this service are public.

langevitour documentation built on May 29, 2024, 8:21 a.m.