DelaunayClassificationError: Delaunay Classification Error (DCE)

View source: R/DelaunayClassificationError.R

DelaunayClassificationErrorR Documentation

Delaunay Classification Error (DCE)

Description

DCE searches for the k-nearest neighbors of the first delaunay neighbors weighted by the Euclidean Distances of the Inputspace. DCE evaluates these neighbors in the Output space. A low value indicates a better two-dimensional projection of the high-dimensional Input space.

Usage

DelaunayClassificationError(Data,ProjectedPoints,Cls,LC,Gabriel=FALSE,
PlotIt=FALSE,Plotter = "native", Colors = NULL,LineColor= 'grey',
main = "Name of Projection", mainSize = 24,xlab = "X", ylab = "Y", xlim, ylim,
pch,lwd,Margin=list(t=50,r=0,l=0,b=0))

Arguments

Data

[1:n,1:d] Numeric matrix with n cases and d variables

ProjectedPoints

[1:n,1:2] Numeric matrix with 2D points in cartesian coordinates

Cls

[1:n] Numeric vector with class labels

LC

Optional, Numeric vector of two values determining grid size of the underlying projection

Gabriel

Optional, Boolean: TRUE/FALSE => Gabriel/Delauny graph (Default: FALSE => Delaunay)

PlotIt

Optional, Boolean: TRUE/FALSE => Plot/Do not plot (Default: FALSE)

Plotter

Optional, Character with plot technique (native or plotly)

Colors

Optional, Character vector of class colors for points

LineColor

Optional, Character of line color used for edges of graph

main

Optional, Character plot title

mainSize

Optional, Numeric size of plot title

xlab

Optional, Character name of x ax

ylab

Optional, Character name of y ax

xlim

Optional, Numeric vector with two values defining x ax range

ylim

Optional, Numeric vector with two values defining y ax range

pch

Optional, Numeric of point size (graphic parameter)

lwd

Optional, Numeric of linewidth (graphic parameter)

Margin

Optional, Margin of plotly plot

Details

Delaunay classification error (DCE) makes an unbiased evaluation of distance and densitiybased structure which ma be even non-linear seperable. First, DCE utilizes the information provided by a prior classification to assess projected structures. Second, DCE applies the insights drawn from graph theory. Details are described in [Thrun/Ultsch, 2018]

Value

list of

DCE

DelaunayClassificationError NOTE the rest is just for development purposes

DCEperPoint

[1:n] unnormalized DCE of each point: DCE = mean(DCEperPoint)

nn

the number of points in a relevant neghborhood: 0.5 * 85percentile(AnzNN)

AnzNN

[1:n] the number of points with a delaunay graph neighborhood

NNdists

[1:n,1:nn] the distances within the relevant neighborhood, 0 for inner cluster distances

HD

[1:nn] HD = HarmonicDecay(nn) i.e weight function for the NNdists: DCEperPoint = HD*NNdists

Note

see also chapter 6 of [Thrun, 2018]

Author(s)

Michael Thrun

References

[Thrun/Ultsch, 2018] Thrun, M. C., & Ultsch, A. : Investigating Quality measurements of projections for the Evaluation of Distance and Density-based Structures of High-Dimensional Data, Proc. European Conference on Data Analysis (ECDA), pp. accepted, Paderborn, Germany, 2018.

Examples

data(Hepta)

InputDistances=as.matrix(dist(Hepta$Data))
projection=Pswarm(InputDistances)
DelaunayClassificationError(Hepta$Data,projection$ProjectedPoints,Hepta$Cls,LC=projection$LC)$DCE



Mthrun/DatabionicSwarm documentation built on Nov. 2, 2023, 6:51 a.m.