User Tools

Site Tools


api:dk11:java:tatukgis.jdk.tgis_classificationpixel

TGIS_ClassificationPixel class

DK11 for Java | tatukgis.jdk.TGIS_ClassificationPixel | Classes | Constructors | Methods | Properties

Class that enables performing advanced pixel data classification in the process of creating choropleth (thematic) maps.

Available also on: Delphi | .NET | ActiveX | Python.

Syntax

// Java
public class TGIS_ClassificationPixel extends TGIS_ClassificationAbstract {
};
// Oxygene
type
  TGIS_ClassificationPixel = public class( TGIS_ClassificationAbstract )
  end;

Inheritance

→ TGIS_Object → TGIS_ClassificationAbstract

Constructors

Inherited Overrides Protected
Name Visibility Description
TGIS_ClassificationPixel() public Creates an object.

Methods

Inherited Overrides Protected
Name Visibility Description
AddClassBreak public Adds a new class break.
(Inherited from TGIS_ClassificationAbstract)
Classify public Performs the classification.
(Inherited from TGIS_ClassificationAbstract)
Classify(TGIS_ParamsList) public Performs the classification and applies to defined ParamsList.
(Inherited from TGIS_ClassificationAbstract)
doCreate protected Internal constructor.
(Inherited from TGIS_ClassificationAbstract)
EstimateNumClasses public Performs the pre-classification and sets NumClasses property.
(Inherited from TGIS_ClassificationAbstract)
MustCalculateStatistics public If True, statistics from layer assigned to classification need to be calculated.
(Inherited from TGIS_ClassificationAbstract)

Properties

Inherited Protected
Name Visibility Description
Band public Band from which values are used in classification.
ClassBreaks public Computed class breaks.
(Inherited from TGIS_ClassificationAbstract)
ColorRamp public The color ramp that is used to assign colors for class breaks; none by default If not provided, StartColor and EndColor will be used.
(Inherited from TGIS_ClassificationAbstract)
ColorRampName public The name of the built-in color ramp that is used to assign colors for class breaks; empty by default.
(Inherited from TGIS_ClassificationAbstract)
EndColor public Ending color used to generate ramp for class breaks; Black by default.
(Inherited from TGIS_ClassificationAbstract)
ForceStatisticsCalculation public Forces the calculation of layer statistics; True by default.
(Inherited from TGIS_ClassificationAbstract)
Interval public Class interval size; default value is 1.
(Inherited from TGIS_ClassificationAbstract)
Layer public Layer assigned to object.
(Inherited from TGIS_ClassificationAbstract)
Method public Classification method; NaturalBreaks by default.
(Inherited from TGIS_ClassificationAbstract)
NumClasses public Number of classes; default is 5, max is 30.
(Inherited from TGIS_ClassificationAbstract)
ShowLegend public If True, features will be shown in legend panel; True by default.
(Inherited from TGIS_ClassificationAbstract)
StartColor public Starting color used to generate ramp for class breaks; White by default.
(Inherited from TGIS_ClassificationAbstract)
Target public Indicates the data to be used for classification; empty by default.
(Inherited from TGIS_ClassificationAbstract)

Remarks

Example

Pseudocode:

// while 'lyr' is opened raster layer
classifier = new TGIS_Classification( lyr );

// select one of available classification methods
classifier.Method = TGIS_ClassificationMethod.EqualInterval;

// specify number of classes
classifier.NumClasses = 5;

// specify attribute field with numerical values
classifier.Band = '1';

// check if layer's statistics require recalculation
if classifier.MustCalculateStatistics then
  lyr.Statistics.Calculate ;

// run classification process, visual properties will be applied automatically
classifier.Classify ;

// check generated class breaks values
// class breaks count equals NumClasses + 1
for i from 0 to classifier.NumClasses
  value = classifier.ClassBreaks[i];

2024/12/20 22:24

Page Tools