matrixToLongTable: Transform a matrix to long table

View source: R/transformations.R

matrixToLongTableR Documentation

Transform a matrix to long table

Description

Transform a matrix to long table

Usage

matrixToLongTable(x, valueLabel = "value", rowLabel = "row", colLabel = "col")

Arguments

x

A matrix

valueLabel

Character string, the label of the value

rowLabel

Character string, the name of the column holding the row names

colLabel

Character string, the name of the column holding the column names

Value

A data.frame

Examples

myMatrix <- matrix(rnorm(24), nrow=4, dimnames=list(LETTERS[1:4], letters[1:6]))
matrixToLongTable(myMatrix)

bedapub/ribiosExpression documentation built on Sept. 2, 2023, 4:37 a.m.