% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/misc.R
\name{flattenPB}
\alias{flattenPB}
\title{flattenPB}
\usage{
flattenPB(pb, norm = TRUE, lfc_group = NULL)
}
\arguments{
\item{pb}{a pseudo-bulk SummarizedExperiment as produced by
`muscat::aggregateData`, with different celltypes/clusters are assays.}

\item{norm}{Logical; whether to calculate logcpm (TMM normalization).}

\item{lfc_group}{the colData column to use to calculate foldchange. If
NULL (default), no foldchange assay will be computed.}
}
\value{
A SummarizedExperiment
}
\description{
Flattens a pseudo-bulk SummarizedExperiment as produced by
`muscat::aggregateData` so that all cell types are represented in a single
assay. Optionally normalizes the data and calculates per-sample logFCs.
}
