hpms: Generate an HPMS Submission File

hpmsR Documentation

Generate an HPMS Submission File

Description

Generate an HPMS submission file in accordance with HPMS Field Manual Supplemental Guidance Requires the scores from score() to be run with verbose = TRUE The reporting year is based on the TMC_Identification year (e.g. use 2021 TMC network for 2021 reporting in 2022) Writes the resulting file to hpms_year.txt

Usage

hpms(
  file,
  tmc_identification,
  lottr_scores,
  tttr_scores,
  phed_scores = NULL,
  occ_fac = 1.7
)

Arguments

file

Output file name. This is the HPMS submittal file.

tmc_identification

Path to TMC_Identification.csv file provided by RITIS with travel time download

lottr_scores

A data.table of LOTTR scores produced using score(..., metric == "LOTTR")

tttr_scores

A data.table of TTTR scores produced using score(..., metric == "TTTR")

phed_scores

A data.table of of PHED scores produced using phed()

occ_fac

Occupancy factor. Default = 1.7

Value

No return value, writes file to disk

Examples

## Not run: 
lottr_scores <- lottr("data/All_Vehicles/al_tt_seconds.csv", verbose = TRUE)
tttr_scores <- tttr("data/Trucks/aldot_2019_trucks.csv", verbose = TRUE)
phed_scores <- phed("Readings.csv", "TMC_Identification.csv",
                    speed_limits = fread("speed_limits.csv"),
                    urban_code = 56139, pm_peak = 3, population = 52898)
hpms("hpms_2020.txt", "TMC_Identification.csv", lottr_scores, tttr_scores, phed_scores)

## End(Not run)


markegge/fhwa_pm3 documentation built on June 16, 2024, 5:45 a.m.