[GIS] How to create a line with all attribute information of the original GPX points

mergeqgistable

I am trying to make a shapefile line contain all the data that the GPX file has.

So i load the gpx file into Qgis, (prompts me for tracks, waypoints, trackpoints, routes, etc)

When i choose "Tracks" the attribute table is empty, just one feature, yet when i choose "Track Points" all the data is in the attribute table ( elevation, time, etc )

I would like to be able to make a shapefile line that contains the trackpoint data. I tried selecting both the track and trackpoint gpx layer together, and then 'save as" a shapefile. when i do, it only seems to save one, either just the track, or just the trackpoints as a shapefile.

The conversion to shapefile goes well when saving each gpx layer separately, … so lets say i have Shapefile.line ( no attributes ) and Shapefile.point ( full attribute table ) . How can i import the data from .point into . line ?

I have tried to merge them, but had no success.

Using Qgis Dufour, on Ubuntu 14.04lts, Gps Garmin Monterra


I have tried the plugin mentioned and have gotten some results, but the resulting line shapefile did not contain any of the information in the attribute table.

Is there not a way to just copy the attribute table from one shapefile, and paste it into another? I have found a way to copy the table to my clipboard, but have not found a way to paste it to another.

( im working on a road, i want my shapefile to appear as a line but contain attribute table information from trackpoint shapefile, both shapefiles were generated by the same GPX file )

Here is a screenshot of both attribute tables, i would like C Mainline to contain all the data from Mainline points

enter image description here

Best Answer

The typical GIS way of doing this is using a prebuilt tool or script to convert point layer data to a line layer. Some key web search phrases you may use to find these tools or scripts are "covert points to lines" or "connect the dots". Here is one plug-in you may try:

https://plugins.qgis.org/plugins/pointstopaths_v02/

If you want to get the attribute info in the new line layer you will have to associate the line segments ID field with the other table related ID field that has the attributes. This process is know as joining. Once the segment info table is joined to the line layer you will need to export out a new layer for the attributes to be kept.