l_getProjection: Query the matrix of projection vectors

Description Usage Arguments Value Examples

View source: R/l_getProjection.R

Description

Query the matrix of projection vectors

Usage

1

Arguments

target

A object returned by l_tour

data

Original data set

Value

a matrix of projection vectors

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
if(interactive()) {
  dat <- iris[,-5]
  p <- l_tour(dat, color = iris$Species,
              as.l_tour = FALSE)
  # scroll the bar
  proj <- l_getProjection(p, dat)
  projected_object <- as.matrix(dat) %*% proj
  # it will not be exactly the same
  plot(projected_object[,1], projected_object[,2],
       col = hex12tohex6(p['color']))
}

loon.tourr documentation built on Oct. 27, 2021, 5:09 p.m.