Hot answers tagged

8

In the Processing Toolbox use the Extract Specific Vertices tool, for the Vertex indices use 0 for the first vertex and -1 for the last vertex. Which one you need will depend on the direction of the line. EDIT: Apologies, I didn't read your question properly, you said automatically. If it's just for display purposed you could use a geometry generator ...


6

Tested on QGIS 2.18 and QGIS 3.4 I can suggest using a "Virtual Layer" through Layer > Add Layer > Add/Edit Virtual Layer... Let's assume there is a polyline layer called "polylines" (blue lines). With the following Query, it is possible to create a point at the end of each line. SELECT st_endpoint(geometry), * FROM "polylines" The output point ...


3

It was not backported to 3.4.x LTR branch, but does currently exist in 3.10.x branch. See the comment here by its developer: Result: Rendering point 3D as a billboard support is added to QGIS 3.10 As well as the commit for it on the QGIS Github: Note that there was no milestone, nor backport specified. This went into master over the summer and made ...


2

If you have polylines stored in shapefile and call them "LINES" in your mxd table of content, below field calculator expression will populate numerical field of your points table by distance from relevant line start: g=arcpy.Geometry() geomList=arcpy.CopyFeatures_management("LINES",g) def Chainage(id,shp): geom=geomList[id] L=geom.measureOnLine (shp....


2

You have these 2 options: 1) You can add all these attributes during the creation of your point file 2) You can add attributes (your layer must be in editing mode) in the attribute table view


2

If you want to write all the values of the ycoord field into a .txt file, you can execute the following code in the Python Console of QGIS (change the parameters with your own): layer = iface.activeLayer() # your layer features = layer.getFeatures() # features of your layer with open('C:/Users/v.bre/Downloads/ycoord.txt','w') as my_file: # Change the path ...


1

Select all the features you want to have a different color. Use the Field Calculator to add a new field. Check the box for "selected features only". Fill in a field name, and fill in a value in the expression area (in my example below, I called the field "category" and filled it with the value 1. Now the point layer has a new field called "category". The ...


1

If you look at the docs for intersectCoordinate method, description says: Returns true if this geometry includes the specified coordinate. If the coordinate is on the boundary of the geometry, returns false.. Since in the case of line geometry intersection is always on the boundary (there is no interior), you get false event if the point is on the line. The ...


1

Another option: use the PostGIS ST_LineMerge function. Here's the previous example redone with it: WITH data(geom) AS (VALUES ('LINESTRING (0 0, 1 1)'), ('LINESTRING (2 2, 1 1)'), ('LINESTRING (7 3, 0 0)'), ('LINESTRING (2 4, 2 3)'), ('LINESTRING (3 8, 1 5)'), ('LINESTRING (1 5, 2 5)'), ('LINESTRING (7 3, 0 7)') ), merged AS (SELECT (ST_Dump( ST_LineMerge(...


1

Já tentou usar o complemento Networks? Você pode instala-lo pelo menu complementos, depois de instalado ele fica no menu processar/caixa de ferramentas. A página do complemento é: https://github.com/crocovert/networks/ Machine translation Have you tried using the Networks add-on? You can install it from the add-ons menu, once installed it is in the render ...


Only top voted, non community-wiki answers of a minimum length are eligible