BixiData {BKTR} | R Documentation |
BIXI Data Class
Description
R6 class encapsulating all BIXI dataframes. It is also
possible to use a light version of the dataset by using the is_light
parameter. In this case, the dataset is reduced to its first 25 stations
and first 50 days. The light version is only used for testing and short examples.
Public fields
departure_df
The departure dataframe
spatial_features_df
The spatial features dataframe
temporal_features_df
The temporal features dataframe
spatial_positions_df
The spatial positions dataframe
temporal_positions_df
The temporal positions dataframe
data_df
The data dataframe
is_light
Whether the light version of the dataset is used
Methods
Public methods
Method new()
Initialize the BIXI data class
Usage
BixiData$new(is_light = FALSE)
Arguments
is_light
Whether the light version of the dataset is used, defaults to FALSE.
Returns
A new BIXI data instance
Method clone()
The objects of this class are cloneable with this method.
Usage
BixiData$clone(deep = FALSE)
Arguments
deep
Whether to make a deep clone.
Examples
# Create a light BIXI data collection instance containing multiple dataframes
# This only uses the first 25 stations and 50 days of the full dataset
bixi_data <- BixiData$new(is_light = TRUE)
# Dataframe containing the position (latitude and longitude) of M stations
bixi_data$spatial_positions_df
# Dataframe containing the time position of N days (O to N-1)
bixi_data$temporal_positions_df
# Dataframe with spatial and temporal features for each day and station (M x N rows)
bixi_data$data_df
[Package BKTR version 0.1.1 Index]