Questions tagged [sorting]

To arrange according to class, kind, or size; classify.

Filter by
Sorted by
Tagged with
5 votes
2 answers
174 views

Saving and applying layout of columns in QGIS Attribute Table

I have multiple projects with similar layers. Here is an example, with all attributes (fields) visible in default order. I do use this layout for certain tasks. But for other tasks, I wish to hide ...
Oisin's user avatar
  • 1,656
1 vote
1 answer
83 views

How to change vertex order to a polyline in QGIS?

I'm trying to change the vertex order of a polyline in QGIS. I have an existing polyline that's closed (last vertex = first vertex). The starting point of this polyline is in a totally casual position....
niubii's user avatar
  • 13
0 votes
1 answer
29 views

Band calculations and sorting within a specified geometry

I am working on a small geographic area (< 50 km sq.) and am trying to find the 5-10 least cloudy Landsat images for my specified area. The issue I have is that if I simply use: imageCollection....
user225452's user avatar
2 votes
1 answer
193 views

GEE: How to sort ImageCollection correctly by system:index

I am very new to GEE and I have the following Problem: I have to create NDVI time series (with MODIS Vegetation indices) and compare the monthly mean value between 2001 and 2021 with the monthly mean ...
Cubozoa13's user avatar
0 votes
1 answer
192 views

How to order attributes by suffix in FME?

I have a table with attributes containing a suffix of the form _DIGIT. FME displays the table like this: country name_0 name_1 name_2 platforms_0 platforms_1 platforms_2 The Netherlands Utrecht ...
saQuist's user avatar
  • 716
5 votes
3 answers
558 views

Permanently sorting table so that field of interest is sorted in the same order as the fid in QGIS

Using 3.22.13, consider a non-spatial GeoPackage attribute table containing one text field, named "field_a". This table has the following form: fid field_a 1  B 2  A 3  X 4  C How can I sort ...
Stu Smith's user avatar
  • 8,094
1 vote
1 answer
326 views

Sorting rows based on calculated values on PostgreSQL's ST_DWithin

I have a question on how to improve sorting performance on PostgreSQL on geospatial data. I want to sort restaurants based on their distance and price, but it's noticeably slower than my study on ...
Yukha Dharmeswara's user avatar
1 vote
2 answers
308 views

Get a specific number of images from a sorted image collection in Google Earth Engine

I want to export the first 10 images of a Landsat image collection sorted based on the "CLOUD_COVER_LAND" property. I know how to extract the least cloudy image of the sorted collection by ...
diego bárb's user avatar
0 votes
1 answer
203 views

Sort SHP features by feature ID in QGIS

I have a shapefile which does not have any ID column. I put them in a validator, which indicates the ID of faulty features, based on the DBF line order. But by opening the shapefile attribute table in ...
Arkeen's user avatar
  • 323
2 votes
1 answer
2k views

Sort by custom expression in QGIS

I would like to sort child records in form view of attributes in QGIS to be sorted by an integer field but in the same time show a different expression in from list. When setup it's working fine - ...
Albine Pro's user avatar
8 votes
1 answer
263 views

Sorting values in Unique Values widget in QGIS

In QGIS 3.24.3 I have a GeoPackage table containing a text field "box_id". Within its Layer Properties > Attributes Form page I have assigned it a Unique Values widget type as shown here: ...
Stu Smith's user avatar
  • 8,094
4 votes
0 answers
188 views

Sorting points to create polygon in PyQGIS

I have list of points and I want to create a polygon. First I need to sort points for that I tried: Find the center point of all points Calculated angle from the center to each point, Based on angle ...
Velugoti Venkateswarlu's user avatar
4 votes
1 answer
228 views

QGIS 3.22 sorting by attributes does not work in gpkg-files

Since I updated from QGIS 3.16 to 3.22 I have the following problem in attribute tables: in gpkg files the sorting option (alphabetical) does not work - sometimes! I tried it with projects in qgz- or ...
Bertram's user avatar
  • 463
6 votes
1 answer
515 views

Sorting drop down lists in value relation widget in QGIS

I have some attributes in my data and want to enable the user to pick values from drop-down lists. The values of the drop-down list change depending on the chosen value of the previous field(s). The ...
Nil's user avatar
  • 1,463
2 votes
1 answer
191 views

GEE Image Collection to Multiband Image Outputs Gibberish

I'm using Landsat imagery in Google Earth Engine and am attempting to convert an image collection to a multiband image. However, before doing so I do two things: I mosaic the images by date so that ...
user5858's user avatar
  • 405
3 votes
1 answer
539 views

Automatically sort table data by specified column when opening attribute table in QGIS

I want the attribute table in QGIS to be automatically sorted by the column I want, so that I don't have to click on the right column every time. At the moment, when I open the attribute table, the ...
Comrade Che's user avatar
  • 7,084
7 votes
1 answer
285 views

Sorting layer order in QGIS based on mixed string/numerical layer names

In QGIS, is there a way to automatically order the layers in the Layers Panel? I'm looking to sort 50 layers, output of a Split vector layer operation (see here) in a predefined order that is not ...
Babel's user avatar
  • 67.1k
8 votes
4 answers
455 views

Sorting/ordering selected features by attribute in QgsVectorLayer using PyQGIS

In a standalone application, I have a layer to which I select some features. Then I need to do an iteration, and I need it to be done in the order of the value of a field/attribute (In my example ...
RBenet's user avatar
  • 760
1 vote
1 answer
161 views

GeoServer WFS - Casting a property to Integer for sorting

I have a WFS query string that ends with: &SORTBY=am_subtype%20DESC This works but am_subtype is a string, so it does not sort the way I'd like it to. Can I cast am_subtype to an Integer somehow ...
user2065855's user avatar
2 votes
2 answers
580 views

Sorting field values within column in table using ArcPy

I have a feature class table named fcwells. It has a bunch of different columns but the column I need sorted is 0Meters. Many fields under 0Meters have multiple values separated by commas and it is ...
Brett Holte's user avatar
-1 votes
1 answer
183 views

Creating table from lists in sorted manner in Google Earth Engine

I have calculated the area coverage of landcover types in a region and sort them now I want to export the results as a table to drive in a sorted manner when I combine them in a new dictionary object ...
Solmaz's user avatar
  • 137
0 votes
2 answers
206 views

sort dictionary datasets based on values in ascending order

i want to sort my dataset and use an example dataset to chack the code. that works and here is the code: var b=ee.List([4.5,2.8,7.4]) var c= ee.List(['a','b','c']) print('b',b) var dict=ee.Dictionary....
Solmaz's user avatar
  • 137
1 vote
0 answers
54 views

How does the expression look like to sort route segments of multiple routes using start and end coordinates of segments in qgis?

I do have a line layer containing multiple route segments. Having a route_id (string type; for example A101-1, B207, ...) as attribute for each segments tells me to which route the segment belongs. ...
mymymy's user avatar
  • 175
1 vote
1 answer
2k views

Sorting dictionary values and getting sorted keys in new dictionary using Google Earth Engine

How can I sort a dictionary's keys in Earth Engine based on their values? For example, I have such a dictionary defined in Earth Engine after some calculations and I want to sort that based on ...
Solmaz's user avatar
  • 137
3 votes
2 answers
2k views

Is there a way to "sort" points in a MultiLineString such that they seem more like a continuous LineString?

Is there a way to "sort" the points of a MultiLineString such that they follow a more sequential order? Let me illustrate what I mean with a graphical example: Input Suppose I have the ...
Felipe D.'s user avatar
  • 2,321
3 votes
1 answer
361 views

Getting fieldnames with QGIS expressions in same order as in attribute table (not alphabetical order)

Context I want to get a list of field names of a layer using QGIS expressions. The function attributes() returns a key:value map of the attribute names and values. By default, the result is sorted ...
Babel's user avatar
  • 67.1k
1 vote
2 answers
129 views

GeoServer 2.20 - view only list of layers in a specified store

Is there any way to view only the layers from a specific store in GeoServer (v 2.20)? I can't find anything online and I don't see any way to do this in the interface. The layer list shows everything ...
JasonBK's user avatar
  • 600
4 votes
1 answer
328 views

Grouping and sorting field values by group in QGIS

I need to sort groups of "Field A" by "Field B" and write the Sort Order to "Field C". All entities of "X" value in "Field A" are ordered amongst ...
MrKingsley's user avatar
  • 1,443
1 vote
1 answer
281 views

FME - how to sort data in verses

I have many elements in my layer. In the table, I have measure - distance and curvature. These two data in columns are connected with each other. For example (first verse): 0 - 35; 4420 - 35; 4157 - ...
adien's user avatar
  • 13
1 vote
0 answers
370 views

Sorting columns in attribute tables in ArcGIS Pro 2.8

I have an attribute table whose columns I want to keep in chronological order, but when I try to drag and sort them, they return to their original order. Is there a way to make them keep the order I ...
Beck's user avatar
  • 191
1 vote
1 answer
183 views

Sorting by multiple fields SearchCursor ArcGIS 10.6

I want to define the values of first row in a sorted table with search cursor. My code is working without sorting, but I don't know how can I integrate into sorting. I would like to see only the ...
GisT's user avatar
  • 81
1 vote
1 answer
627 views

Sort column by values in ui.Chart.feature.byProperty in Google Earth Engine

I am creating a bar chart of band importance of a random forest classifier in GEE. The default bar order seems to be by name. How can I sort the columns in descending order depending on each column ...
OscarBau's user avatar
  • 700
9 votes
2 answers
791 views

Numbering adjacent points/centroids in sequential order using QGIS

I am using QGIS 3.18. I have, for example, this layer with points or centroids (with x, y coordinates) I want to enumerate the points from right to left (for example) and top to bottom like this: I ...
wollyka's user avatar
  • 447
0 votes
0 answers
63 views

Deleting the old layer set automatically - after sorting layers of one specific group within the table of contents alphabetically

I'd like to reorder the layers within ONE specific group of the TOC alphabetically by layer name, but without reordering the top level layers or the layers of other groups. @GérmanCarillo helped me to ...
jaysigg's user avatar
  • 477
7 votes
2 answers
1k views

Sorting layers by name in one specific group of QGIS layer tree

I'd like to reorder the layers within ONE specific group of the TOC alphabetically by layer name, but without reordering the top level layers or the layers of other groups. I found the following ...
jaysigg's user avatar
  • 477
10 votes
2 answers
740 views

Sorting records by attribute in shapefile using PyShp

I know how to get records in a shapefile using PyShp, but how to sort records by an attribute (i.e., "NAME" or "POPULATION")? My code: import shapefile file = "c:/data/cities....
user183925's user avatar
2 votes
0 answers
129 views

Selecting, sorting, and grouping spatial data (lines) by length and proximity

I'm working on a project where I have a bunch of lines inside of polygonal land parcels. Here's a rough sketch of what I'm talking about: I need to further subdivide these parcels into sections that ...
Adam Malenczak's user avatar
1 vote
1 answer
209 views

How to make a linked-list in Google Earth Engine?

Now, after Noel Gorelick's very helpfull code, i have a sorted list with two-segment: var list = ee.List([ [101, 103], [102, 103], [103, 109], [109, 122], [117, 156], [122, 133], [133, ...
Mehmet C ARSLANOGLU's user avatar
1 vote
1 answer
294 views

How put order in multiple raster file in RasterMosaic in FME? [closed]

I have couple of raster files which I want to mosaic in a specific order. How I can do that?
Firoza Akter's user avatar
1 vote
1 answer
489 views

Sort attribute table in an atlas layout with PyQGIS 3

I wrote a script that automate the production of an atlas layout with PyQGIS 3 that works well but it remains a detail I can't figure out. Each page of my atlas contains a map zoomed on a particular ...
Juliette Lapeyre's user avatar
0 votes
1 answer
1k views

Using arcpy.da.SearchCursor to sort field in attribute table by ascending order

I am using ArcMap 10.6 with Python 2.7.14 with ArcPy. I want to sort a field named Seq_ID in my attribute table by ascending order using ArcPy. I believe I have to use arcpy.da.SearchCursor. Here is ...
user avatar
0 votes
1 answer
441 views

Sorting GeoJSON features array by property value [closed]

I am looking to sort a GeoJSON file on a property so I can then slice it keeping only the top 5 features. For example, I wish to take this GeoJSON and sort the file in descending order by the ...
LoF10's user avatar
  • 103
0 votes
2 answers
394 views

Sort Custom Tileset Features in MapBox Studio or GL

I have a large number (hundreds of thousands) of point features uploaded to my account in MapBox studio as a dataset, and have generated a tileset based on that dataset. This tileset is used in a ...
Ty Hayes's user avatar
  • 101
1 vote
1 answer
327 views

Is there a way to sort the QGIS attribute table by date modified?

I was wondering if there was a way to sort the attribute table in QGIS Pi by date modified. I have been digitizing a large area and I need to delete the last 50-100 features that were digitized. My ...
AndrewRobert's user avatar
0 votes
0 answers
25 views

Sorting alphanumeric characters [duplicate]

I am new to QGIS. The version I am trying to get used to is v3.6. I have been trying to sort this table in map layout but still ending up as displayed in the table below. Need help to sort in ...
user173106's user avatar
0 votes
1 answer
180 views

Using Sort tool in ModelBuilder of ArcMap

I am using the model builder in ArcMap to create zonal statistics as table (daily time series-so iterating rasters in the beginning). The tool works fine, it's just that I have another additional step,...
Arthur_Morgan's user avatar
4 votes
1 answer
864 views

QGIS Attribute Table on print layout not sorting

I've added in an attribute table to a print layout and am trying to sort numerically ascending using Plot Order For some reason it doesn't change order whatever field I use to sort the items in the ...
HeyHoWheresJoe's user avatar
10 votes
3 answers
663 views

Sorting text column by numbers with letters

I have a text column. It's made up of the numbers 1, 2, 3 up to 1650, which are currently not in increasing order. However, it also includes text such as 520a, 639a, 639b, 639c. Sorting on increasing ...
Alasdair's user avatar
  • 101
2 votes
2 answers
1k views

Sorting raster stack by dates in R

I need suggestion on how to sort a raster stack by dates. A reproducible example is in the following: library(raster) Create a reproducible rasterstack; set.seed(123) r1 <- raster(nrows = 6, ncols ...
SA Khan's user avatar
  • 197
3 votes
2 answers
596 views

Adding consecutive unique ID for distinct value sets and sorting by date [closed]

I have a layer with features, which have a unique ID, called "Object_id". A second column is "Date", a third called "info" (see below). What I need is to fill the fourth ...
Bjoern's user avatar
  • 283