logo-header

 
 

syntax

  • centroid_or_mid(polygonset)

definition

centroid_or_mid(polygonset) results in a point data item with the centroid or the mid of the polygonset argument.

description

The centroid_or_mid function results in the centroid if it is located within the polygon or else in the mid of the polygon.

applies to

Point data item polygonset with fpoint or dpoint value type and composition type polygon

since version

5.15

example

attribute<point_rd> centroid_or_mid (District) := 
centroid_or_mid(district/geometry);
district/geometry   centroid_or_midDistrict
{21 {403025, 113810}{4 {402955, 113049}
{17 {400990, 113269}{4 {401159, 112704}
{19 {401238, 115099}{4 {401268, 114017}
domain District, nr of rows = 3

see also


OBJECT VISION BV
Vrije Universiteit
De Boelelaan 1085
1081 HV Amsterdam
The Netherlands

tel: +31 (0)20 598 9083
fax:+31 (0)20 598 9904