User Tools

Site Tools


api:dk11:net:tatukgis.ndk.tgis_statisticsvector

TGIS_StatisticsVector class

DK11 for .NET | TatukGIS.NDK.TGIS_StatisticsVector | Classes | Constructors | Methods | Properties

Statistics class for vector layers.

Available also on: Delphi | Java | ActiveX.

Syntax

// C#
public class TGIS_StatisticsVector : TGIS_StatisticsLayer
{
}
' VisualBasic
Public Class TGIS_StatisticsVector
  Inherits TGIS_StatisticsLayer
End Class
// Oxygene
type
  TGIS_StatisticsVector = public class( TGIS_StatisticsLayer )
  end;

Inheritance

Constructors

Inherited Overrides Protected
Name Visibility Description
TGIS_StatisticsVector() public Create an object.
(Overrides TGIS_StatisticsLayer.TGIS_StatisticsLayer())

Methods

Inherited Overrides Protected
Name Visibility Description
Add public Add statistics result definition.
(Inherited from TGIS_StatisticsAbstract)
AddAll public Add statistics result definitions for all available datasets.
AddAll(TGIS_StatisticalFunctions) public
AddAllFields public Add statistics result definitions for all fields from vector layer.
AddAllFields(TGIS_StatisticalFunctions) public Add statistics result definitions for all fields from vector layer.
Calculate public Calculate requested statistics from filtered elements of the layer.
doCreate protected "private constructor"
(Inherited from TGIS_StatisticsAbstract)
Get public Get statistics result by name.
(Inherited from TGIS_StatisticsAbstract)
LoadFromFile public Parse statistics file and load all information into parent layer
(Inherited from TGIS_StatisticsAbstract)
Reset public Reset statistics object to initial state.
(Inherited from TGIS_StatisticsAbstract)
ResetModified public Undo changes in requested statistics definitions.
(Inherited from TGIS_StatisticsAbstract)
SaveToFile public Save layer statistics into auxiliary file.
(Inherited from TGIS_StatisticsAbstract)

Properties

Inherited Protected
Name Visibility Description
Age public Age of the statistics.
(Inherited from TGIS_StatisticsAbstract)
AvailableResults public List of available results names; read-only.
(Inherited from TGIS_StatisticsAbstract)
DefinedResults public List of already defined results names; read-only.
(Inherited from TGIS_StatisticsAbstract)
FastStatistics public Determines the state if "Fast Statistics" was computed; read-only.
(Inherited from TGIS_StatisticsAbstract)
Layer public Layer assigned to statistics; read-only.
(Inherited from TGIS_StatisticsLayer)
Modified public True if requested statistics have changed.
(Inherited from TGIS_StatisticsAbstract)
Obsolete public Check validity of statistics.
(Inherited from TGIS_StatisticsAbstract)
UseBesselCorrection public If True, statistics class will use Bessel's correction.
(Inherited from TGIS_StatisticsAbstract)

Remarks

This class inherits from TGIS_StatisticsAbstract and is specialised for vector layers, e.g.:

  • AddAllFields method,
  • Statistics results can be additionally narrowed by setting UseSelected and Query properties.

See TGIS_StatisticsAbstract class.

Example

Pseudocode:

// layer.Statistics is an instance of TGIS_StatisticsAbstract so casting is needed
stats = TGIS_StatisticsVector(layer.Statistics);

// add all fields from vector layer
stats.AddAllFields(TGIS_StatisticalFunctions.BasicStatistics);

stats.Calculate;

// demand a result
stats_result = stats.Get(<valid_name>);

Valid names are existing fields' names (listed in stats.AvailableResults list).

Use later like in TGIS_Abstract example.

2019/08/29 01:16