usair_combine: Traverse from one or more selected edges toward adjacent...

Description Usage Arguments Value Examples

Description

From a graph object of class dgr_graph move to adjacent nodes from a selection of one or more selected edges where the edges are outward edges to those nodes. This creates a selection of nodes. An optional filter by node attribute can limit the set of nodes traversed to.

Usage

1
usair_combine(usair_dataset, years)

Arguments

usair_dataset

the name of the dataset to use; options are co (carbon monoxide), no2 (nitrogen dioxide), so2 (sulfur dioxide), ozone (ground-level ozone), pm10 (particulate matter up to 10 microns in diameter), pm25_frm (particulate matter up to 2.5 microns in diameter, using a Federal Reference Method (FRM) instrument or its equivalent (FEM)), pm25_nfrm (same as pm25_frm but not using an FRM or FEM instrument ), and met (meteorology).

years

a vector of years that represents the starting and ending years to include in the combined dataset.

Value

a dplyr tb_df data frame with combined data for multiple years.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
## Not run: 
# Get carbon monoxide (CO) data for the years 1992,
# 1993, and 1994 in a single data frame
co_1992_1994 <- usair_combine("co", c(1992, 1994))

# Get a count of records for this dataset
nrow(co_1992_1994)
#> [1] 12584901

## End(Not run)

rich-iannone/USAir documentation built on May 27, 2019, 7:57 a.m.