knitr::opts_chunk$set( collapse = TRUE, comment = "#>" )
Two sample data-sets can be found within the package. One for the municipality of Smallingerland and another for the municipality of Texel. Both data sets have data for 2015 and 2016. The structure of the file directories are the same as the structure constantly used by the ftw
package to return the function values.
Here is an example on how to load the data:
library(ftw) path <- system.file("extdata", package = "ftw") data_tmp <- read_ftw(path, year = c(2015, 2016), study_area = "Smallingerland") data_tmp
A summary of the data will allow us to know basic information regarding the data, specifically the number of edges, nodes and unique trips for each year.
summary(data_tmp)
Notice that we loaded the data for both years. This will result on an object of class ftw_tmp
, which is meant to enable the user to do comparisons between years when exploring the data.
class(data_tmp)
If we load the data only for one year, the result will be an object of class ftw_atmp
, let's see an example.
library(ftw) path <- system.file("extdata", package = "ftw") data_atmp <- read_ftw(path, year = 2016, study_area = "Texel") data_atmp
class(data_atmp) summary(data_atmp)
The next vignette will show the different ways to explore the data depending on its class.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.