Skip to contents

This function tells RAP to extract the variables you want from the .dataset database file and to create a CSV file within the main RAP project folder. When you want to use the CSV file in your own data analysis project, use download_project_data(). You probably don't need to run this function often, probably only once at the start of your project. NOTE: This function takes 5-60 minutes to run on the UKB RAP, so be careful with just randomly running it.

Usage

proj_create_dataset(fields, output_path, database_id = dare_project_record_id)

Arguments

fields

A character vector of field IDs you want to extract from the UKB database. Select the variable ids from the rap_variables dataset.

output_path

The name of the output CSV file.

database_id

The ID of the dataset, defaults to the one we use in the Steno UK Biobank DARE project.

Value

Outputs character string of the results from the command sent to RAP.

Examples

if (FALSE) { # \dontrun{
proj_create_dataset(
  c("eid", "p31", "p34"),
  proj_create_path_dataset(rap_get_user())
)
} # }