TCGAbarcode: Parse data from TCGA barcode

View source: R/TCGAbarcode.R

TCGAbarcodeR Documentation

Parse data from TCGA barcode

Description

This function returns the specified snippet of information obtained from the TCGA barcode.

Usage

TCGAbarcode(
  barcodes,
  participant = TRUE,
  sample = FALSE,
  portion = FALSE,
  plate = FALSE,
  center = FALSE,
  index = NULL
)

Arguments

barcodes

A character vector of TCGA barcodes

participant

Logical (default TRUE) participant identifier chunk

sample

Logical (default FALSE) includes the numeric sample code of the barcode and the vial letter

portion

Logical (default FALSE) includes the portion and analyte codes of the barcode

plate

Logical (default FALSE) returns the plate value

center

Logical (default FALSE) returns a matrix with the plate and center codes

index

An optional numeric vector indicating barcode positions when split by the delimiter (i.e., hyphen '-'). For example, an index of c(1, 2) corresponds to 'TCGA-ZZ' in TCGA-ZZ-A1A1.

Value

A character vector or data matrix of TCGA barcode information

Author(s)

M. Ramos

Examples

barcodes <- c("TCGA-B0-5117-11A-01D-1421-08",
"TCGA-B0-5094-11A-01D-1421-08",
"TCGA-E9-A295-10A-01D-A16D-09")

## Patient identifiers
TCGAbarcode(barcodes)

## Sample identifiers
TCGAbarcode(barcodes, sample = TRUE)


waldronlab/BiocInterfaces documentation built on Nov. 4, 2024, 7:48 a.m.