arrow_open_data: Open an Arrow Data Set

View source: R/arrow.R

arrow_open_dataR Documentation

Open an Arrow Data Set

Description

Open an Arrow Data Set

Usage

arrow_open_data(
  sources = NULL,
  schema_file = NULL,
  schema = NULL,
  schema_name = NULL,
  assign_schema = T,
  to_duck = F,
  partitioning = NULL,
  unify_schemas = NULL,
  format = c("parquet", "arrow", "ipc", "feather", "csv", "tsv", "text"),
  ...
)

Arguments

sources

vector of locations

schema_file

Location of the schema file

schema_name
format

options are 'parquet' 'ipc' 'feather' 'csv' 'tsv'

Examples

library(asbtools)
arrow_open_data(sources = "Desktop/data/usa_spending/assistance/", schema_file = "Desktop/data/usa_spending/assistance/2021/2021.gz.parquet", schema_name = "assistance")
asbtools::arrow_open_data(sources  = "Desktop/abresler.github.io/r_packages/govtrackR/data/thousand_talents.tsv.gz", format = "csv") %>% count(nameSponsor, sort =  T) %>% collect()
arrow_open_data(sources  = "Desktop/abresler.github.io/r_packages/govtrackR/data/thousand_talents.tsv.gz", format = "csv", to_duck = T)


abresler/asbtools documentation built on July 28, 2022, 11:04 p.m.