Learn R Programming

vein (version 1.1.3)

Vehicles: Construction function for class "Vehicles"

Description

Vehicles returns a tranformed object with class "Vehicles" and units 'veh'. The type of objects supported are of classes "matrix", "data.frame", "numeric" and "array". If the object is a matrix it is converted to data.frame. If the object is "numeric" it is converted to class "units".

Usage

Vehicles(x, ..., time = NULL)

# S3 method for Vehicles print(x, ...)

# S3 method for Vehicles summary(object, ...)

# S3 method for Vehicles plot( x, pal = "colo_lightningmccarl_into_the_night", rev = TRUE, bk = NULL, fig1 = c(0, 0.8, 0, 0.8), fig2 = c(0, 0.8, 0.55, 1), fig3 = c(0.7, 1, 0, 0.8), mai1 = c(1, 0.82, 0.82, 0.42), mai2 = c(1.8, 0.82, 0.5, 0.42), mai3 = c(1, 1, 0.82, 0.2), bias = 1.5, ... )

Value

Objects of class "Vehicles" or "units"

Arguments

x

Object with class "Vehicles"

...

ignored

time

Character to be the time units as denominator, eg "1/h"

object

Object with class "Vehicles"

pal

Palette of colors available or the number of the position

rev

Logical; to internally revert order of rgb color vectors.

bk

Break points in sorted order to indicate the intervals for assigning the colors.

fig1

par parameters for fig, par.

fig2

par parameters for fig, par.

fig3

par parameters for fig, par.

mai1

par parameters for mai, par.

mai2

par parameters for mai, par.

mai3

par parameters for mai, par.

bias

positive number. Higher values give more widely spaced colors at the high end.

Examples

Run this code
if (FALSE) {
lt <- rnorm(100, 300, 10)
class(lt)
vlt <- Vehicles(lt)
class(vlt)
plot(vlt)
LT_B5 <- age_hdv(x = lt,name = "LT_B5")
summary(LT_B5)
plot(LT_B5)
}

Run the code above in your browser using DataLab