aw: Average Weight for hourly traffic data.

View source: R/aw.R

awR Documentation

Average Weight for hourly traffic data.

Description

aw average weight form traffic.

Usage

aw(
  pc,
  lcv,
  hgv,
  bus,
  mc,
  p_pc,
  p_lcv,
  p_hgv,
  p_bus,
  p_mc,
  w_pc = 1,
  w_lcv = 3.5,
  w_hgv = 20,
  w_bus = 20,
  w_mc = 0.5,
  net
)

Arguments

pc

numeric vector for passenger cars

lcv

numeric vector for light commercial vehicles

hgv

numeric vector for heavy good vehicles or trucks

bus

numeric vector for bus

mc

numeric vector for motorcycles

p_pc

data-frame profile for passenger cars, 24 hours only.

p_lcv

data-frame profile for light commercial vehicles, 24 hours only.

p_hgv

data-frame profile for heavy good vehicles or trucks, 24 hours only.

p_bus

data-frame profile for bus, 24 hours only.

p_mc

data-frame profile for motorcycles, 24 hours only.

w_pc

Numeric, factor equivalence

w_lcv

Numeric, factor equivalence

w_hgv

Numeric, factor equivalence

w_bus

Numeric, factor equivalence

w_mc

Numeric, factor equivalence

net

SpatialLinesDataFrame or Spatial Feature of "LINESTRING"

Value

data.frame with with average weight

Examples

## Not run: 
data(net)
data(pc_profile)
p1 <- pc_profile[, 1]
aw1 <- aw(pc = net$ldv*0.75,
            lcv = net$ldv*0.1,
            hgv = net$hdv,
            bus = net$hdv*0.1,
            mc = net$ldv*0.15,
            p_pc = p1,
            p_lcv = p1,
            p_hgv = p1,
            p_bus = p1,
            p_mc = p1)
head(aw1)

## End(Not run)

vein documentation built on May 29, 2024, 7:20 a.m.