Skip to contents

Extract ADRR flight list in an interval of dates

Usage

adrr_flights_tidy(conn = NULL, wef, til)

Arguments

conn

Database connection or instantiate the default one.

wef

With EFfect date (included) at Zulu time in a format recognized by lubridate::as_datetime()

til

unTILl date (excluded) at Zulu time in a format recognized by lubridate::as_datetime()

Value

A dbplyr::tbl_dbi() with the following columns (as defined in the Aviation Data Repository for Research manual):

Flight details

  • ECTRL ID: flight unique id.

  • ADEP: ICAO code of the Aerodrome of DEParture

  • ADEP Latitude: ADEP latitude (decimal degrees North)

  • ADEP Longitude: ADEP longitude (decimal degrees East)

  • ADES: ICAO code of the Aerodrome of DEStination

  • ADES Latitude: ADES latitude (decimal degrees North)

  • ADES Longitude: ADES longitude (decimal degrees East)

  • FILED OFF BLOCK TIME: (Last) filed off-block time

  • FILED ARRIVAL TIME: (Last) filed arrival time

  • ACTUAL OFF BLOCK TIME: actual off-block time for flown (M3) trajectory

  • ACTUAL ARRIVAL TIME: arrival time for flown (M3) trajectory

  • AC Type: the ICAO code for the aircraft type, for example A30B for an Airbus A-300B2-200.

  • AC Operator: the ICAO Airline Designator, i.e. OAL for Olympic

  • AC Registration: the aircraft registration (with spaces, dashes, ... stripped), e.g. GEUUU

  • ICAO Flight Type: flight type (see FPL Item 8). Possible values:

    • S for scheduled air service

    • N for non-scheduled air service

  • STATFOR Market Segment: market segment type as defined on the Market Segment Rules, it can be:

    • “Mainline”

    • “Regional”

    • “Low-Cost”

    • “Business Aviation”

    • “All-Cargo”

    • “Charter” (Non-Scheduled)

    • “Military”

    • “Other”

    • "Not classified"

  • Requested FL: requested cruising flight level (FL)

  • Actual Distance Flown (nm): route length (in Nautical Miles) for for flown (M3) trajectory

Note

You need to either provide a connection conn that has access to SWH_FCT.DIM_FLIGHT_TYPE_RULE (for FLT_RULES), PRUDEV.V_COVID_DIM_AO (for aircraft and aircraft group info) and SWH_FCT.V_FAC_FLIGHT_MS (for market segment info) or go with the default which uses PRU_READ to establish a db_connection().

Examples

if (FALSE) { # \dontrun{
withr::local_envvar(c(TZ = "UTC", ORA_SDTZ = "UTC", NLS_LANG = ".AL32UTF8"))
conn <- withr::local_db_connection(db_connection(schema = "PRU_READ"))
wef <- "2025-01-01"
til <- "2025-01-04"
adrr_flights_tidy(conn, wef, til)
} # }