View source: R/geco_subjects.R
fetch_subjects | R Documentation |
Fetch subject data from the Generable API for a specific project.
fetch_subjects(
project = NULL,
project_version_id = NULL,
event_type = NULL,
annotate = T,
.dots = list(),
...
)
project |
Project name. If NULL, defaults to value of environment variable GECO_API_PROJECT |
project_version_id |
Project version. If NULL, defaults to the most recent version of the project if provided, or the value of environment variable GECO_API_PROJECT_VERSION |
event_type |
If this argument is provided, event data that matches this event type will be joined into the return data.frame. Default is NULL (no event data). |
annotate |
if 'TRUE', annotate subject data with dose data. Default is 'TRUE'. |
.dots |
Alternate method of passing filters as a named list, rather than in ... |
... |
Optional filters applied to subjects data, provided as name-value pairs where names are fields and values contain a subset of valid values Example: trial_name = c('trial-A', 'trial-N'), performance_status = c(0,1) |
This function retrieves subject data from the Generable API. This includes subject-level covariates.
As a convenience, event data can be included in the returned 'data.frame' by
specifying the 'event_type' argument; the data returned from fetch_events
matching the 'event_type' will be merged into the returned data.
Authentication (see login
) is reqiured prior to use
and this pulls subject data from the Generable API.
data.frame of subject-level data, including information about the trial and trial_arms
A project can be specified by using the project name or a specific project version.
If a project is specified using the name, data is fetched for the latest version of the project.
If a project is specified using the project version, the project name is not required.
If neither a project nor a project version is provided, the default project or project version is used. These are set by the environment variables GECO_API_PROJECT and GECO_API_PROJECT_VERSION
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.