load_panel {beadplexr}R Documentation

Load panel information

Description

The panel information are stored in resources in the package directory and can be loaded by providing a file or panel name, or a search pattern

Usage

load_panel(.file_name = NULL, .panel_name = NULL, .panel_pattern = NULL)

Arguments

.file_name

Character vector giving the name of an external panel info file. See below for the expected components.

.panel_name

Character vector giving the name of the panel. See below for accepted panel names.

.panel_pattern

The pattern to look for. Can be a regular expression.

Details

If an explicit .file_name is given, .panel_name and .panel_pattern are ignored. If no file is given but a .panel_name is, the .panel_pattern i ignored. Only if no .file_name and .panel_name are given, is the .panel_pattern used.

Value

A list

Included panels

Example panel file

The panel information files are formatted in YAML. It has three main parts:

The 'Human Th Cytokine Panel (13-plex)' YAML file is found in /resources/legendplex_human_th_cytokine_panel_13-plex.yml of the package directory.

Examples

library(beadplexr)

.panel_name <- "Human T Helper Cytokine Panels (13-plex)"
panel_info <- load_panel(.panel_name = .panel_name)
panel_info$panel_name

.file_name <- system.file("resources",
                          "legendplex_human_cytokine_panel_2_13-plex.yml",
                          package = "beadplexr")
panel_info <- load_panel(.file_name = .file_name)
panel_info$panel_name

panel_info <- load_panel(.file_name = .file_name, .panel_name = .panel_name)
panel_info$panel_name

suppressWarnings(
# The pattern matches several files, which raises a warning
panel_info <- load_panel(.panel_pattern = "panel_2_13-plex")
)
panel_info$panel_name


[Package beadplexr version 0.5.0 Index]