createFlightgeo: Return merged flight + geo object

Description Usage Arguments Value

Description

This function takes a list of geomatrices (geo.RDS) and flight data (df.RDS) and returns essentially the same flight data df with a geo column of class sfc_LINESTRING. Since there are 5 columns within the geomatrix, and only 4 can be within a sfc column, one must be dropped. The resulting sf geo dataframe can be used to map routes and further analysis.

Usage

1
2
3
4
5
6
createFlightgeo(
  geomatrix,
  flights,
  simplify = F,
  drop = c("velocity", "altitude", "time")
)

Arguments

geomatrix

A list of matrices containing 10-second data for lat, long, alt, velocity; "geo.RDS"

flights

A dataframe of all the flights information within routes of interest; "df.RDS"

simplify

A T/F option of whether to simplify the geo data after calculating the distance

drop

User must choose to drop velocity, elevation, or time to create the sf geo dataframe

Value

A df with rows representing a flight, with many rows containing flight data and geodata.


DatascribeConsulting/MonaRk documentation built on May 4, 2021, 5:28 a.m.