filters.sort#
The sort filter orders a point view based on the values of a Dimensions. The sorting can be done in increasing (ascending) or decreasing (descending) order.
Example#
[
"unsorted.las",
{
"type":"filters.sort",
"dimension":"X",
"order":"ASC"
},
"sorted.las"
]
Note
See filters.label_duplicates for an example of using filters.sort to sort multiple dimensions at once.
Options#
- dimensions
A list of dimensions in the order on which to sort the points. [Required]
- order
The order in which to sort, ASC or DESC [Default: “ASC”]
- where
An expression that limits points passed to a filter. Points that don’t pass the expression skip the stage but are available to subsequent stages in a pipeline. [Default: no filtering]
- where_merge
A strategy for merging points skipped by a
where
option when running in standard mode. Iftrue
, the skipped points are added to the first point view returned by the skipped filter. Iffalse
, skipped points are placed in their own point view. Ifauto
, skipped points are merged into the returned point view provided that only one point view is returned and it has the same point count as it did when the filter was run. [Default:auto
]