geo:remove-duplicate-vertices( $region as cts:region, [$options as xs:string*] ) as cts:region
Remove duplicate (adjacent) vertices.
Whether a vertex counts as a duplicate depends on the governing coordinate system and whether it is single or double precision unless tolerance is specified.
If the region
parameter is a box, circle, or point,
no action is taken and the region is returned unchanged.
The value of the precision
option takes precedence over
that implied by the governing coordinate system name, including the
value of the coordinate-system
option. For example, if the
governing coordinate system is "wgs84/double" and the precision
option is "float", then the operation uses single precision.
geo:remove-duplicate-vertices( cts:polygon(( cts:point(40.1234567890,-120.1234567890), cts:point(40.123456543,-120.123456543), cts:point(40.12455,-120.123467), cts:point(40.13456,-120.1455195)))) => A cts:region with the following coordinates: 40.123457,-120.12346 40.12455,-120.12347 40.13456,-120.14552 40.123457,-120.12346"
Stack Overflow: Get the most useful answers to questions from the MarkLogic community, or ask your own question.