Learn R Programming

wizaRdry (version 0.2.0)

mongo: Fetch data from MongoDB to be stored in a data frame

Description

Fetch data from MongoDB to be stored in a data frame

Usage

mongo(
  collection_name,
  db_name = NULL,
  identifier = NULL,
  chunk_size = NULL,
  verbose = FALSE,
  interview_date = NULL
)

Value

A data frame containing the MongoDB data with superkeys first

Arguments

collection_name

The name of the MongoDB collection

db_name

The database name (optional)

identifier

Field to use as identifier (optional)

chunk_size

Number of records per chunk (optional)

verbose

Logical; if TRUE, displays detailed progress messages. Default is FALSE.

interview_date

Optional; can be either: - A date string in various formats (ISO, US, etc.) to filter data up to that date - A boolean TRUE to return only rows with non-NA interview_date values

Examples

Run this code
if (FALSE) {
# Get data from MongoDB collection
data <- mongo("collection_name")
}

Run the code above in your browser using DataLab