| Title: | GPS Track Point Information Extractor |
|---|---|
| Description: | Focused on extracting important data from track points such as speed, distance, elevation difference and azimuth.(PLAZA, J. et al., 2022) <doi:10.1016/j.applanim.2022.105643>. |
| Authors: | Wagner Martins dos Santos [aut, cre]
|
| Maintainer: | Wagner Martins dos Santos <[email protected]> |
| License: | GPL-3 |
| Version: | 1.0.0 |
| Built: | 2026-05-16 05:55:37 UTC |
| Source: | https://github.com/cran/gps.track |
Allows extracting and generating new information from track points data collected with GPS.
path_gps( filename = NULL, layer = "track_points", time_zone = "Etc/GMT-0", zone_correction = "Etc/GMT+3", arq_type = c("shp", "gpx") )path_gps( filename = NULL, layer = "track_points", time_zone = "Etc/GMT-0", zone_correction = "Etc/GMT+3", arq_type = c("shp", "gpx") )
filename |
string designating the file .gpx or .shp path in geographic coordinates |
layer |
string that designates the layer with the trackpoint data when arq_type = "gpx", in case arq_type = "shp" layer is ignored |
time_zone |
string designating the gps default time zone |
zone_correction |
string designating the time zone for correction |
arq_type |
string that designates whether the file is type "shp" or "gpx", "shp" default |
returns a data frame with information about time, coordinates, elevation, distance, speed, elevation difference and azimuth (always calculated in relation to the later point)
path.file.ex <- base::system.file("extdata", "trajeto_teste.shp", package = "gps.track") df.gps <- path_gps( filename = path.file.ex, time_zone = "Etc/GMT-0", zone_correction = "Etc/GMT+3", arq_type = "shp" )path.file.ex <- base::system.file("extdata", "trajeto_teste.shp", package = "gps.track") df.gps <- path_gps( filename = path.file.ex, time_zone = "Etc/GMT-0", zone_correction = "Etc/GMT+3", arq_type = "shp" )
Allows converting data.frame with coordinates of points into sf with coordinates of line.
point_to_line( data = NULL, col_long = "long", col_lat = "lat", crs_proj = "+proj=longlat +datum=WGS84" )point_to_line( data = NULL, col_long = "long", col_lat = "lat", crs_proj = "+proj=longlat +datum=WGS84" )
data |
Data frame containing coordinates of points to convert to lines |
col_long |
String containing the name of the column containing the longitude |
col_lat |
String containing the name of the column containing the latitude |
crs_proj |
String containing the proj4string |
returns a sf object with coordinates of line.
path.file.ex <- base::system.file("extdata", "df_gps.csv", package = "gps.track") df.gps <- read.table(path.file.ex,h=TRUE) df.gps.line <- point_to_line( data = df.gps, col_long = "long", col_lat = "lat", crs_proj = "+proj=longlat +datum=WGS84" )path.file.ex <- base::system.file("extdata", "df_gps.csv", package = "gps.track") df.gps <- read.table(path.file.ex,h=TRUE) df.gps.line <- point_to_line( data = df.gps, col_long = "long", col_lat = "lat", crs_proj = "+proj=longlat +datum=WGS84" )