1

I have a series of points along a road that I want to use to separate plots. I have tried using the point to line tool to create a line from these points using QGIS. However, it creates a single line with no attributes to separate each segment.

Is there a way to create separate lines for each segment (each straight section would be its own line)?

I started with the points. This is the line that I created. I would like the line between each point to be separate from each other line.

PolyGeo
65.5k29 gold badges115 silver badges349 bronze badges
asked Nov 22, 2022 at 0:33
1
  • Can you add a screenshot showing the attribute table? Commented Nov 24, 2022 at 18:35

2 Answers 2

3

EDIT:

My earlier answer (following this edit) describes the use of the PointsToPaths tool, which has inexplicably been removed from the Plugins repository, after having been updated to 3.x (https://github.com/chiatt/pointstopaths). More's the pity.

Fortunately, however, there is a functionally equivalent alternative:

How to to create lines from points where the point attributes are transferred to the line segments?

Oprionally, if a user absolutely required the PointsToPaths tool, they could download a separate install of the last version of QGIS 2.x (2.18.28), and then install the 2.x version of the PointsToPaths plugin.

End of edit......

Use the QGIS PointsToPaths plugin (note the plural "paths"). It will create a separate line segment for each sequential pair of points. Additionally, each new line segment will contain the attributes from the two points that defined it. For details, see my answer at: Creating line layer from point layer with start and end attributes in QGIS

answered Nov 22, 2022 at 5:39
2
  • PointsToPaths apparently is not compatible with QGIS 3 and can't be installed in current versions of the app. Commented Apr 11, 2024 at 14:35
  • @Kirkman14 Please see my updated answer. Commented Apr 14, 2024 at 15:26
2

Using QGIS, you can use the Split Lines at Points tool. the tool is located under the Processing toolbox → SAGA → Feature - Lines → Split Lines at Points .

enter image description here

You need to use a small Epsilon value such as 0.001 to make sure the line will be split at each point

Before using the tool

enter image description here

After using the tool

enter image description here

answered Nov 22, 2022 at 1:02

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.