Learn R Programming

archetypal (version 1.0.0)

find_outmost_points: Function which finds the outmost points in order to be used as initial solution in archetypal analysis

Description

Function which finds the outmost points in order to be used as initial solution in archetypal analysis

Usage

find_outmost_points(df, kappas)

Arguments

df

The data frame with dimensions n x d

kappas

The number of archetypes

Value

A list with members:

  1. outmost, the first kappas outmost points as rows of data frame

  2. outmostall, all the outmost points that have been found as rows of data frame

  3. outmostfrequency, a matrix with frequency and cumulative frequency for outmost rows

Warning

This is a rather naive way to find the outmost points of a data frame and it should be used with caution since for a n x d matrix we need in general 8 n^2/(2^30) Gb of memory RAM for numeric case. Check your machine and use it.

See Also

find_furthestsum_points, find_outmost_convexhull_points,

find_outmost_projected_convexhull_points & find_outmost_partitioned_convexhull_points

Examples

Run this code
# NOT RUN {
data("wd2") #2D demo 
df=wd2
yy=find_outmost_points(df,kappas=3)
yy$outmost #the rows of 3 outmost points
yy$outmostall #all outmost found
yy$outmostfrequency #frequency table for all
df[yy$outmost,] #the 3 outmost points
#
###
#
data("wd3") #3D demo 
df=wd3
yy=find_outmost_points(df,kappas=4)
yy$outmost #the rows of 4 outmost points
yy$outmostall #all outmost found
yy$outmostfrequency #frequency table for all
df[yy$outmost,] #the 4 outmost points
# }

Run the code above in your browser using DataLab