Learn R Programming

galah (version 2.1.1)

print_galah_objects: Print galah objects

Description

As of version 2.0, galah supports several bespoke object types. Classes data_request, metadata_request and files_request are for starting pipes to download different types of information. These objects are parsed using collapse() into a query object, which contains one or more URLs necessary to return the requested information. This object is then passed to compute() and/or collect(). Finally, galah_config() creates an object of class galah_config which (unsurprisingly) stores configuration information.

Usage

# S3 method for data_request
print(x, ...)

# S3 method for files_request print(x, ...)

# S3 method for metadata_request print(x, ...)

# S3 method for query print(x, ...)

# S3 method for computed_query print(x, ...)

# S3 method for query_set print(x, ...)

# S3 method for galah_config print(x, ...)

Value

Print does not return an object; instead it prints a description of the object to the console

Arguments

x

an object of the appropriate class

...

Arguments to be passed to or from other methods

Examples

Run this code
if (FALSE) {
# The most common way to start a pipe is with `galah_call()`
# later functions update the `data_request` object
galah_call() |> # same as calling `request_data()`
  filter(year >= 2020) |>
  group_by(year) |>
  count()

# Metadata requests are formatted in a similar way
request_metadata() |>
  filter(field == basisOfRecord) |>
  unnest()

# Queries are converted into a `query_set` by `collapse()`
x <- galah_call() |> # same as calling `request_data()`
  filter(year >= 2020) |>
  count() |>
  collapse()
print(x)
  
# Each `query_set` contains one or more `query` objects
x[[3]]
}

Run the code above in your browser using DataLab