ArcadeExpression
for summarizing aggregated data from an
AggregationFeatureReduction
.
Feature reduction uses statistical methods to aggregate geoelements into logical groups based on their location. Attribute values
for each group (AggregateGeoElement
) can be summarized for any numeric field using a specified AggregateStatisticType
, such as
the average, maximum, or sum. A common workflow is to summarize aggregated groups with the number of geoelements they represent.
- Since:
- 200.3.0
-
Property Summary
TypePropertyDescriptionA display name for the field that appears in aPopup
, label, and other UI elements.A name that uniquely identifies the aggregate field within theAggregationFeatureReduction.getAggregateFields()
collection.An Arcade expression that must evaluate to either a string or a number.An attribute name from the source dataset that contains numeric values to summarize.Defines the type of statistic for summarizing values returned fromstatisticFieldNameProperty()
orstatisticExpressionProperty()
. -
Constructor Summary
ConstructorDescriptionAggregateField
(String name, ArcadeExpression statisticExpression, AggregateStatisticType statisticType) Creates an AggregateField object.AggregateField
(String name, String statisticFieldName, AggregateStatisticType statisticType) Creates an AggregateField object. -
Method Summary
Modifier and TypeMethodDescriptionA display name for the field that appears in aPopup
, label, and other UI elements.getAlias()
Gets the value of thealias
property.getName()
Gets the value of thename
property.Gets the value of thestatisticExpression
property.Gets the value of thestatisticFieldName
property.Gets the value of thestatisticType
property.A name that uniquely identifies the aggregate field within theAggregationFeatureReduction.getAggregateFields()
collection.void
Sets the value of thealias
property.void
Sets the value of thename
property.void
setStatisticExpression
(ArcadeExpression statisticExpression) Sets the value of thestatisticExpression
property.void
setStatisticFieldName
(String statisticFieldName) Sets the value of thestatisticFieldName
property.void
setStatisticType
(AggregateStatisticType statisticType) Sets the value of thestatisticType
property.An Arcade expression that must evaluate to either a string or a number.An attribute name from the source dataset that contains numeric values to summarize.Defines the type of statistic for summarizing values returned fromstatisticFieldNameProperty()
orstatisticExpressionProperty()
.
-
Property Details
-
alias
A display name for the field that appears in aPopup
, label, and other UI elements.Attempting to set the value to null will throw a NullPointerException exception.
- Since:
- 200.3.0
- See Also:
-
name
A name that uniquely identifies the aggregate field within theAggregationFeatureReduction.getAggregateFields()
collection. Clusters will not draw correctly if this property is empty or does not match the field name used byAggregationFeatureReduction.rendererProperty()
.For example, an AggregateField that summarizes 'population' values might have the alias 'population_sum'.
Attempting to set the value to null will throw a NullPointerException exception.
- Since:
- 200.3.0
- See Also:
-
statisticExpression
An Arcade expression that must evaluate to either a string or a number.The expression is evaluated for each geoelement represented by the
AggregateGeoElement
and the result of the expression is summarized using the given statistic type.- Since:
- 200.3.0
- See Also:
-
statisticFieldName
An attribute name from the source dataset that contains numeric values to summarize.Alternatively, an Arcade expression (
statisticExpressionProperty()
) can be used instead of anAggregateStatisticType
. If present, this value always takes precedence overAggregateField.statisticExpressionProperty()
.Attempting to set the value to null will throw a NullPointerException exception.
- Since:
- 200.3.0
- See Also:
-
statisticType
Defines the type of statistic for summarizing values returned fromstatisticFieldNameProperty()
orstatisticExpressionProperty()
.Attempting to set the value to null will throw a NullPointerException exception.
- Since:
- 200.3.0
- See Also:
-
-
Constructor Details
-
AggregateField
public AggregateField(String name, ArcadeExpression statisticExpression, AggregateStatisticType statisticType) Creates an AggregateField object.- Parameters:
name
- a name that uniquely identifies the aggregate field within theAggregationFeatureReduction.getAggregateFields()
collectionstatisticExpression
- an Arcade expression that evaluates to either a string or a numberstatisticType
- type of statistic used to summarize numeric field for aggregated geoelements- Throws:
NullPointerException
- if name is nullNullPointerException
- if statisticExpression is nullNullPointerException
- if statisticType is null- Since:
- 200.3.0
-
AggregateField
Creates an AggregateField object.- Parameters:
name
- a name that uniquely identifies the aggregate field within theAggregationFeatureReduction.getAggregateFields()
collectionstatisticFieldName
- an attribute name from the source dataset that contains numeric values to summarizestatisticType
- type of statistic used to summarize numeric field for aggregated geoelements- Throws:
NullPointerException
- if name is nullNullPointerException
- if statisticFieldName is nullNullPointerException
- if statisticType is null- Since:
- 200.3.0
-
-
Method Details
-
aliasProperty
A display name for the field that appears in aPopup
, label, and other UI elements.Attempting to set the value to null will throw a NullPointerException exception.
- Returns:
- the
alias
property - Since:
- 200.3.0
- See Also:
-
getAlias
Gets the value of thealias
property.- Property description:
- A display name for the field that appears in a
Popup
, label, and other UI elements.Attempting to set the value to null will throw a NullPointerException exception.
- Returns:
- the value of the
alias
property - Since:
- 200.3.0
- See Also:
-
setAlias
Sets the value of thealias
property.- Property description:
- A display name for the field that appears in a
Popup
, label, and other UI elements.Attempting to set the value to null will throw a NullPointerException exception.
- Parameters:
alias
- the value for thealias
property- Since:
- 200.3.0
- See Also:
-
nameProperty
A name that uniquely identifies the aggregate field within theAggregationFeatureReduction.getAggregateFields()
collection. Clusters will not draw correctly if this property is empty or does not match the field name used byAggregationFeatureReduction.rendererProperty()
.For example, an AggregateField that summarizes 'population' values might have the alias 'population_sum'.
Attempting to set the value to null will throw a NullPointerException exception.
- Returns:
- the
name
property - Since:
- 200.3.0
- See Also:
-
getName
Gets the value of thename
property.- Property description:
- A name that uniquely identifies the aggregate field within the
AggregationFeatureReduction.getAggregateFields()
collection. Clusters will not draw correctly if this property is empty or does not match the field name used byAggregationFeatureReduction.rendererProperty()
.For example, an AggregateField that summarizes 'population' values might have the alias 'population_sum'.
Attempting to set the value to null will throw a NullPointerException exception.
- Returns:
- the value of the
name
property - Since:
- 200.3.0
- See Also:
-
setName
Sets the value of thename
property.- Property description:
- A name that uniquely identifies the aggregate field within the
AggregationFeatureReduction.getAggregateFields()
collection. Clusters will not draw correctly if this property is empty or does not match the field name used byAggregationFeatureReduction.rendererProperty()
.For example, an AggregateField that summarizes 'population' values might have the alias 'population_sum'.
Attempting to set the value to null will throw a NullPointerException exception.
- Parameters:
name
- the value for thename
property- Since:
- 200.3.0
- See Also:
-
statisticExpressionProperty
An Arcade expression that must evaluate to either a string or a number.The expression is evaluated for each geoelement represented by the
AggregateGeoElement
and the result of the expression is summarized using the given statistic type.- Returns:
- the
statisticExpression
property - Since:
- 200.3.0
- See Also:
-
getStatisticExpression
Gets the value of thestatisticExpression
property.- Property description:
- An Arcade expression that must evaluate to either a string or a number.
The expression is evaluated for each geoelement represented by the
AggregateGeoElement
and the result of the expression is summarized using the given statistic type. - Returns:
- the value of the
statisticExpression
property - Since:
- 200.3.0
- See Also:
-
setStatisticExpression
Sets the value of thestatisticExpression
property.- Property description:
- An Arcade expression that must evaluate to either a string or a number.
The expression is evaluated for each geoelement represented by the
AggregateGeoElement
and the result of the expression is summarized using the given statistic type. - Parameters:
statisticExpression
- the value for thestatisticExpression
property- Since:
- 200.3.0
- See Also:
-
statisticFieldNameProperty
An attribute name from the source dataset that contains numeric values to summarize.Alternatively, an Arcade expression (
statisticExpressionProperty()
) can be used instead of anAggregateStatisticType
. If present, this value always takes precedence overAggregateField.statisticExpressionProperty()
.Attempting to set the value to null will throw a NullPointerException exception.
- Returns:
- the
statisticFieldName
property - Since:
- 200.3.0
- See Also:
-
getStatisticFieldName
Gets the value of thestatisticFieldName
property.- Property description:
- An attribute name from the source dataset that contains numeric values to summarize.
Alternatively, an Arcade expression (
statisticExpressionProperty()
) can be used instead of anAggregateStatisticType
. If present, this value always takes precedence overAggregateField.statisticExpressionProperty()
.Attempting to set the value to null will throw a NullPointerException exception.
- Returns:
- the value of the
statisticFieldName
property - Since:
- 200.3.0
- See Also:
-
setStatisticFieldName
Sets the value of thestatisticFieldName
property.- Property description:
- An attribute name from the source dataset that contains numeric values to summarize.
Alternatively, an Arcade expression (
statisticExpressionProperty()
) can be used instead of anAggregateStatisticType
. If present, this value always takes precedence overAggregateField.statisticExpressionProperty()
.Attempting to set the value to null will throw a NullPointerException exception.
- Parameters:
statisticFieldName
- the value for thestatisticFieldName
property- Since:
- 200.3.0
- See Also:
-
statisticTypeProperty
Defines the type of statistic for summarizing values returned fromstatisticFieldNameProperty()
orstatisticExpressionProperty()
.Attempting to set the value to null will throw a NullPointerException exception.
- Returns:
- the
statisticType
property - Since:
- 200.3.0
- See Also:
-
getStatisticType
Gets the value of thestatisticType
property.- Property description:
- Defines the type of statistic for summarizing values returned from
statisticFieldNameProperty()
orstatisticExpressionProperty()
.Attempting to set the value to null will throw a NullPointerException exception.
- Returns:
- the value of the
statisticType
property - Since:
- 200.3.0
- See Also:
-
setStatisticType
Sets the value of thestatisticType
property.- Property description:
- Defines the type of statistic for summarizing values returned from
statisticFieldNameProperty()
orstatisticExpressionProperty()
.Attempting to set the value to null will throw a NullPointerException exception.
- Parameters:
statisticType
- the value for thestatisticType
property- Since:
- 200.3.0
- See Also:
-