New answers tagged

0 votes

Create vector layer/virtual layer with dynamic number of features in QGIS

Assuming you want each of the points to have an identical geometry, you could use a recursive CTE and generate a row (with unique id) for each layer as such: WITH seq AS (SELECT 1 AS n UNION ALL ...
  • 7,574
0 votes

Exporting project with all files, properties and dependencies using QGIS

I tried Project Packager by Tarot Osuji - https://github.com/tarot231 Although it doesn't have a rating yet it seems to have more than 2,000 downloads. So, I risked trying it. It seems to be working ...
0 votes

QGIS clipping virtual raster into tiles using grid layer (polygons)

Are you willing to try a solution in R ? library(sf) library(terra) grid <- st_read(dsn = "polygon_grid.gpkg") nr = nrow(terrace_grid) r <- rast("uas.vrt") lapply(1:nr, ...
  • 14.6k
0 votes

QGIS auxiliary label locations: determining their storage locations

When you move the first label, you must select the primary key to use for joining with internal data storage. Solution 1 When this is created (as it is the case with you), you automatically find two ...
  • 45.1k
1 vote

Adding multiple points using Excel data in QGIS

If you have a text file (removed the spaces from the one you provided): Name,Latitude,Longitude,A1,A2,A3 City1,44.499232,23.651273,1,1,1 City2,44.199232,23.251273,1,0,1 in data.txt, you can proceed ...
  • 356
2 votes
Accepted

SVG or PNG image from web as maker symbol (QGIS)

It works but you have to make sure to use the correct URL. You have a link that points to a website (html file) containinge a link to the SVG: https://commons.wikimedia.org/wiki/File:LDB-blau-OSM.svg, ...
  • 45.1k
1 vote

Deleting vertices inside polygon area in QGIS

To identify the vertices to delete, you can check the interio angle at each vertex and where this angle is very high (near to 360 degrees), you can delete the vertex. To measure the interior anlge, I ...
  • 45.1k
0 votes

Download of QGIS Version 3.24 'Tisler' not available

Here are the direct download links (2022-10-01): dmg: https://download.qgis.org/downloads/macos/pr/qgis_pr_final-3_24_0_20220223_132611.dmg md5: https://download.qgis.org/downloads/macos/pr/...
  • 7,063
0 votes
Accepted

Download of QGIS Version 3.24 'Tisler' not available

You can download older QGIS point releases (pr) for MacOS from https://download.qgis.org/downloads/macos/pr
  • 54.2k
1 vote

Deleting vertices inside polygon area in QGIS

Try these geoprocessing tools: Snap geometries to layer and snap the layer to itself Buffer with 0 distance Snap points to grid
  • 55.4k
1 vote
Accepted

Copy/Paste of features into existing PostGIS table

One way to do it, from the postgis side, is to add a new serial column and set it as the primary key: alter table your_table add column pk serial primary key; This will provide QGIS the next sequence ...
  • 6,584
4 votes

Deleting vertices inside polygon area in QGIS

If the vertices immediately before and after the ones that are within the polygon are coincident, the solution could be running the Processing > Vector geometry > Fix geometries tool from the ...
5 votes
Accepted

Display both edges of adjoining polygons in QGIS

This is probably very "tuned" for my data and not optimal, but using a small negative buffer that is roughly the width of your outline should give you the impression you might be after. Here ...
  • 54k
2 votes

Creating Square Buffer in QGIS?

I recently wanted to do the same thing as the OP, but rather than irregular-shaped buffers of irregular polygons, I wanted actual squares. Here is an approach I used in QGIS 3.16, I hope it might be ...
1 vote

Rank values in a row with QGIS field calculator

Here's my convoluted QGIS expression answer - but it only takes the top 5 as in it cuts off after #5, it cannot actually rank the numbers where there are duplicates. In which case, if your #5 position ...
  • 7,574
3 votes

How to show points on LineString in QGIS?

Add a new symbol layer of type marker line and opt to show a marker on every vertex. Eventually click on the said marker to customize it.
  • 36k
3 votes
Accepted

How to show points on LineString in QGIS?

Add a new symbol layer () of type Geometry Generator and select the geometry type to Point / Multi Point use this expression: nodes_to_points($geometry).
  • 1,796
1 vote

QGIS split HTML code table into different fields

A robust solution that fully parses any syntactically valid HTML table, extracting whatever field names are within it, will probably require writing a Python script which uses an XML converter like ...
  • 6,533
2 votes
Accepted

How can I transform a StringList to one String

If you want to replace texts inside a list, you will need to loop throw that list. array_foreach( array:="field-name", -- set inside double quotes the StringList field name ...
  • 1,796
1 vote

Layer just for annotations

In QGIS >= 3.22 there is the possibility to create an annotation layer. You need to activate Annotations Toolbar in View\Toolbars. You will see something like this: Use the first button for ...
  • 1,978
4 votes

Importing CSV or Excel file into QGIS to make shape file (polygon)

You dont need to specify what coordinate represents which location and not that it is a Polygon because your datasource is already provided as WKT where these are specified. Try this query: Select ...
  • 27.3k
0 votes

Text annotation scaling

Has there been any development on this issue? I am having the same problem coupled with scaling issues between a Microsoft surface and external display. I managed to solve the scaling issues but the ...
1 vote
Accepted

How to permanently combine rasters in QGIS?

One way to do it is to export your desired visualization as an image (Project/import/export/Export map to image). Just make sure of the following a) calculate the extentent. If you want the whole ...
0 votes

Vector Bender in QGIS 3.10 not aligning

Make sure that Vector Bender Layer is on the same Coordinate System as the layers on your project. When creating a "Pair Layer" using the plugin interface - the Coordinate System of this new ...
  • 1
1 vote

Clip raster by extent creating Band 1,2,3 from Band 1 (Palette)

I suppose that your raster is not really converted into RGB but the GeoPackage raster driver has a peculiar behavior in how it reports the bands. See https://gdal.org/drivers/raster/gpkg.html#opening-...
  • 54.1k
0 votes

Attribute aggregation - from line to point

this one also worked. if("diameter_valve" is NULL,aggregate( layer:= 'waterpipe_pipe', aggregate:='concatenate', expression:=to_string("diameter"), concatenator:=', ', filter:=...
0 votes

Attribute aggregation - from line to point

This expression worked for me, thanks for help if("diameter_valve" is null, overlay_nearest('waterpipe',diameter_pipe,max_distance:=0.01)[0],"diameter_valve")
1 vote

Finding where to close polyline using QGIS technique that resemble how US Census Geography's Inland Water is calculated

Hypothesis There is one continues line representing edge of water - both for open waters, and inland water The line has known direction, and the water is on the known side in regards of line ...
  • 9,296
0 votes

@row_number with virtual layer in QGIS

You can use ROW_NUMBER() to generate a row number as long as there is some other field to use in the OVER parameter, doesn't matter if it's non-unique. Apparently, using geometry field works (tested ...
  • 7,574
0 votes

I am importing layers from a DWG file into QGIS, and they are visible in the "Layers" panel, but they are not visible in the layout

A lot depends on how the original dwg was set up. Sometimes features that appear to be in a specific layer in CAD will end up on another layer because the block itself is on that other layer. ...
  • 7,574
0 votes

Searching for single Layer in Layers Panel of QGIS?

For QGIS 3.> for layer in QgsProject.instance().mapLayers().values(): if 'Municipal_Boundaries_of_NJ' in layer.name(): iface.setActiveLayer(layer) iface.legendInterface()....
  • 1,537
1 vote
Accepted

Aggregating points within certain distance and keeping all points info using QGIS

I'm not sure if this is best, but I think it will work. I wasn't able to find a plugin or other way to accomplish all your requirements. DBSCAN Calculate field with a value of Name plus CLUSTER_ID. ...
  • 3,050
2 votes

Calculate mean in Qgis filter

In version 3.22 this worked for me. Open the Attribute Table, choose the Filter button and then use this formula in the field you want to filter. mean("SHAPE_AREA") Make sure to change ...
  • 3,050
2 votes
Accepted

Python script in toolbox

You need to actually get the layer from the context argument of the function with QgsProcessingContext.getMapLayer(identifier) -> QgsMapLayer (source) I have also changed ...
3 votes

Extract QGIS text label position as polygon feature

Not 100% what you are looking for but hopefully a start. This will only work for labels which are in Curved placement mode. You need to select the layer from which you want to calculate the polygons ...
  • 1,215
0 votes

Creating a map of only a specific region with OpenStreetMap

If you're looking for OSM-derived vector data of British Columbia, I think that the best option is to download it entirely from Geofabrik in a GIS compatible format. Here you could find the entire ...
2 votes
Accepted

Attribute aggregation - from line to point

Use the following expression on the point layer and adapt it to your needs. It checks whether the point layer's attribute named value is 0: If not, the current value of value will be returned. if ...
  • 45.1k
2 votes

Normalize images for Sentinel

There are several product levels for Sentinel-2. For vegetation indices, I would recommend using bottom-of-atmosphere products (level 2A). No need for normalization as far as I know. Please note that ...
  • 437
0 votes

Accurate way to show values of each classification range in the legend in QGIS?

I would write it as follows, if accuracy is important for the cut-offs: Legend_Category_1: >= 1000, < 2700 Legend_Category_2: >= 2700, < 9200 This would let you know, if we are not talking ...
  • 1
0 votes

Joining attributes by location where percentage of polygon feature is more within a polygon in QGIS

For a Python answer without QGIS, it is possible to do this with geopandas as well. Given two GeoDataframes, A and B: geom_b: str = 'geom_b' geom_b_area: str = 'geom_b_area' B[geom_b] = B.geometry B[...
1 vote

Joining attributes by location where percentage of polygon feature is more within a polygon in QGIS

QGIS has a "Join attributes by location" process that includes the METHOD parameter, option 2: "Take attributes of the feature with largest overlap only (one-to-one)", use it with ...
0 votes

Error when clipping raster by mask layer (polygon) in QGIS

Maybe you are clipping the temporary file. try to save the file then clip
  • 1
2 votes

modify symbol/stroke of digitized line used during digitizing?

Options --> Digitizing --> Rubberband
  • 1,215
0 votes
Accepted

How to uncheck no data value option in Python

If you need to disable nodata value I believe it means that the nodata is set wrong in the source data. Therefore I suggest to correct the source data with gdal_edit.py https://gdal.org/programs/...
  • 54.1k
0 votes

Joining attributes by location where percentage of polygon feature is more within a polygon in QGIS

Add an $id to your small features Run intersect with the small features as first and the large features as second input. This a) splits your small features at the borders of the large ones, and b) ...
  • 13.4k
1 vote

Getting all symbols to render when using Point Displacement in QGIS

I think you would be better of by using a single symbol composed of two half circle and control the fill color of each half using data defined override. You may just use a CASE WHEN expression ...
  • 12.4k
0 votes

Extract subset of linestring based on distance

...found the Service Area function, which does the trick
-2 votes

Python script in toolbox

Processing give you access to the layer features data only, but not to the layer instance itself in project. So, you have to create your own little python plugin, not algorithm. Create ui form (run ...
1 vote

Create polygon from a raster in specific areas

This amounts to translating the values ​​contained in the pixels to obtain a layer vectorized thematic information. It is a work of classification. There are several methods. You can do it with QGIS (...
  • 723
0 votes

QGIS Triangle marker size control

Use the SVG triangle. Select the equilateral SVG triangle, unlock the lock in the right of Width and Height settings, then set the expression in Width and Height. This are my expressions: Width: &...
  • 1,796

Top 50 recent answers are included