% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/listToMap.R, R/mapToList.R
\name{listToMap}
\alias{listToMap}
\alias{mapToList}
\title{Convert map from data.frame or DataFrame to list and vice versa}
\usage{
listToMap(listmap)

mapToList(dfmap, assayCol = "assay")
}
\arguments{
\item{listmap}{A named \code{list} object containing \code{DataFrame}s
with "primary" and "colname" columns}

\item{dfmap}{A \code{data.frame} or \code{DataFrame} object with
identifiers in the first column}

\item{assayCol}{A character vector of length one indicating the assay
names column}
}
\value{
A \linkS4class{DataFrame} class object of names

A \code{list} object of DataFrames for each assay
}
\description{
The \code{mapToList} function provides a convenient way of reordering a
\code{data.frame} to a \code{list}. The \code{listToMap} function does the
opposite by taking a \code{list} and converting it to \code{DataFrame}.
}
\section{Functions}{
\itemize{
\item \code{listToMap}: The inverse of the listToMap operation
}}

\examples{
example("MultiAssayExperiment")

## Create a sampleMap from a list using the listToMap function
sampMap <- listToMap(maplist)

## The inverse operation is also available
maplist <- mapToList(sampMap)
}
