Create a dataset from a CollectiveAccess instance.
Usage
collective_access_stream(
ca_table,
table_name = ca_table,
query = "*",
features = NULL,
base_url = config::get("tessistream")$collective_access_base_url,
login = config::get("tessistream")$collective_access_login,
batch_size = 100L,
...
)
collective_access_login(login, base_url)
collective_access_search(ca_table, query, base_url, login, bundles = NULL)
collective_access_c(...)
Arguments
- ca_table
character base CollectiveAccess table for the query (e.g.
ca_entities
,ca_occurrences
, etc.)- table_name
character output table name
- query
character search query
- features
list of features to include in the dataset. List names will be used as the names of output columns, list values identify the bundle (or a list of bundles that will concatenated) for the output column. Each bundle identifier can itself be a list in order to specify additional parameters (e.g.
template
,delimiter
, etc.)Example:
list( "idno" = "idno", "name" = "preferred_labels", "season" = "ca_occurrences.hierarchy.preferred_labels", "date" = list("productionDate","screeningDate"), "artists" = list("ca_entities" = list( "template" = "<unit relativeTo='ca_entities' delimiter='|'> ^preferred_labels (^relationship_typename) </unit>") ) )
- base_url
character CollectiveAccess base API endpoint ending in
service.php
orservice.php/json
- login
character in the format of
username:password
for authenticating with CollectiveAccess- batch_size
integer number of records to request per query
- ...
Arguments passed on to
tessilake::write_cache
incremental
boolean, whether to call cache_update or cache_write to update the cached dataset.
sync
boolean, whether or not to sync the written cache to other storages
- bundles
list of bundles, as described in the CollectiveAccess API documentation. The name should be a bundle specifier and the value should be a list of parameters or an empty list.
Value
character authorization token
data.table with list columns corresponding to the items in bundles
.