Package elki.visualization.projections
Class Simple1D
- java.lang.Object
-
- elki.visualization.projections.AbstractProjection
-
- elki.visualization.projections.AbstractFullProjection
-
- elki.visualization.projections.AbstractSimpleProjection
-
- elki.visualization.projections.Simple1D
-
- All Implemented Interfaces:
FullProjection
,Projection
,Projection1D
,VisualizationItem
public class Simple1D extends AbstractSimpleProjection implements Projection1D
Dimension-selecting 1D projection.- Since:
- 0.4.0
- Author:
- Erich Schubert
-
-
Field Summary
Fields Modifier and Type Field Description (package private) int
dnum
Our dimension, starting with 0-
Fields inherited from class elki.visualization.projections.AbstractProjection
scales
-
Fields inherited from interface elki.visualization.projections.Projection
INVSCALE, SCALE
-
-
Constructor Summary
Constructors Constructor Description Simple1D(Projector p, LinearScale[] scales, int dnum)
Simple 1D projection using scaling only.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected double[]
dearrange(double[] v)
Undo the rearrangement of components.double
fastProjectDataToRenderSpace(double[] data)
Project a data vector from data space to rendering space.double
fastProjectDataToRenderSpace(NumberVector data)
Project a data vector from data space to rendering space.double
fastProjectRelativeDataToRenderSpace(double[] data)
Project a data vector from data space to rendering space.double
fastProjectRelativeDataToRenderSpace(NumberVector data)
Project a data vector from data space to rendering space.double
fastProjectRelativeScaledToRender(double[] v)
Project a vector from scaled space to rendering space.double
fastProjectScaledToRender(double[] v)
Project a vector from scaled space to rendering space.java.lang.String
getMenuName()
Name to display in the menu.protected double[]
rearrange(double[] v)
Method to rearrange components.-
Methods inherited from class elki.visualization.projections.AbstractSimpleProjection
flipSecondEquals, projectRelativeRenderToScaled, projectRelativeScaledToRender, projectRenderToScaled, projectScaledToRender
-
Methods inherited from class elki.visualization.projections.AbstractFullProjection
projectDataToRenderSpace, projectDataToRenderSpace, projectDataToScaledSpace, projectDataToScaledSpace, projectRelativeDataToRenderSpace, projectRelativeDataToRenderSpace, projectRelativeDataToScaledSpace, projectRelativeDataToScaledSpace, projectRelativeRenderToDataSpace, projectRelativeScaledToDataSpace, projectRenderToDataSpace, projectScaledToDataSpace
-
Methods inherited from class elki.visualization.projections.AbstractProjection
getInputDimensionality, getProjector, getScale
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface elki.visualization.projections.Projection
getInputDimensionality, getProjector, getScale
-
-
-
-
Constructor Detail
-
Simple1D
public Simple1D(Projector p, LinearScale[] scales, int dnum)
Simple 1D projection using scaling only.- Parameters:
p
- Projectorscales
- Scales to usednum
- Dimension (starting at 0)
-
-
Method Detail
-
fastProjectDataToRenderSpace
public double fastProjectDataToRenderSpace(double[] data)
Description copied from interface:Projection1D
Project a data vector from data space to rendering space.- Specified by:
fastProjectDataToRenderSpace
in interfaceProjection1D
- Parameters:
data
- vector in data space- Returns:
- vector in rendering space
-
fastProjectDataToRenderSpace
public double fastProjectDataToRenderSpace(NumberVector data)
Description copied from interface:Projection1D
Project a data vector from data space to rendering space.- Specified by:
fastProjectDataToRenderSpace
in interfaceProjection1D
- Parameters:
data
- vector in data space- Returns:
- vector in rendering space
-
fastProjectScaledToRender
public double fastProjectScaledToRender(double[] v)
Description copied from interface:Projection1D
Project a vector from scaled space to rendering space.- Specified by:
fastProjectScaledToRender
in interfaceProjection1D
- Parameters:
v
- vector in scaled space- Returns:
- vector in rendering space
-
fastProjectRelativeDataToRenderSpace
public double fastProjectRelativeDataToRenderSpace(double[] data)
Description copied from interface:Projection1D
Project a data vector from data space to rendering space.- Specified by:
fastProjectRelativeDataToRenderSpace
in interfaceProjection1D
- Parameters:
data
- vector in data space- Returns:
- vector in rendering space
-
fastProjectRelativeDataToRenderSpace
public double fastProjectRelativeDataToRenderSpace(NumberVector data)
Description copied from interface:Projection1D
Project a data vector from data space to rendering space.- Specified by:
fastProjectRelativeDataToRenderSpace
in interfaceProjection1D
- Parameters:
data
- vector in data space- Returns:
- vector in rendering space
-
fastProjectRelativeScaledToRender
public double fastProjectRelativeScaledToRender(double[] v)
Description copied from interface:Projection1D
Project a vector from scaled space to rendering space.- Specified by:
fastProjectRelativeScaledToRender
in interfaceProjection1D
- Parameters:
v
- vector in scaled space- Returns:
- vector in rendering space
-
rearrange
protected double[] rearrange(double[] v)
Description copied from class:AbstractSimpleProjection
Method to rearrange components.- Specified by:
rearrange
in classAbstractSimpleProjection
- Parameters:
v
- double[] to rearrange- Returns:
- rearranged copy
-
dearrange
protected double[] dearrange(double[] v)
Description copied from class:AbstractSimpleProjection
Undo the rearrangement of components.- Specified by:
dearrange
in classAbstractSimpleProjection
- Parameters:
v
- double[] to undo the rearrangement- Returns:
- rearranged-undone copy
-
getMenuName
public java.lang.String getMenuName()
Description copied from interface:VisualizationItem
Name to display in the menu. May benull
or empty string.- Specified by:
getMenuName
in interfaceVisualizationItem
- Overrides:
getMenuName
in classAbstractProjection
- Returns:
- Menu name.
-
-