getDemographics: Get demographic data

View source: R/getDemographics.R

getDemographicsR Documentation

Get demographic data

Description

This is a thin wrapper around labkey.selectRows().

Usage

getDemographics(colSelect = NULL)

Arguments

colSelect

(optional) a vector of comma separated strings specifying which columns of a dataset or view to import

Value

A data.frame containing LabKey demographic data with the columns specified in the single parameter provided.

Examples

## Not run: 
## Needs a connection to a LabKey server
library(nprcgenekeepr)
siteInfo <- getSiteInfo()
colSet <- siteInfo$lkPedColumns
source <- " generated by getDemographics: "
pedSourceDf <- tryCatch(getDemographics(colSelect = colSet),
  warning = function(wCond) {
    cat(paste0("Warning", source, wCond),
      name = "nprcgenekeepr"
    )
    return(NULL)
  },
  error = function(eCond) {
    cat(paste0("Error", source, eCond),
      name = "nprcgenekeepr"
    )
    return(NULL)
  }
)

## End(Not run)


nprcgenekeepr documentation built on July 26, 2026, 5:06 p.m.