% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/seqwrap.R
\name{swcontainer}
\alias{swcontainer}
\title{seqwrap container class}
\arguments{
\item{.data}{A list containing initial data (inherited from S7::class_list)}

\item{modelfun}{A function used to fit models}

\item{arguments}{A list of arguments for the fitting function}

\item{data}{A data frame or list of data frames with target data}

\item{rownames}{Logical, should row names be used as target IDs?}

\item{metadata}{A data frame with sample information}

\item{targetdata}{A data frame with target-wise information}

\item{samplename}{Character for sample name identification}

\item{additional_vars}{Character vector of additional variables}

\item{summary_fun}{A function for summarizing models}

\item{eval_fun}{A function for evaluating models}

\item{exported}{A list of objects to export to workers}

\item{model_print}{Character representation of model function}

\item{arguments_print}{Character representation of arguments}
}
\value{
An S7 object of class \code{swcontainer} bundling data, metadata,
and the modelling function plus arguments to be consumed by \code{seqwrap()}.
}
\description{
The seqwrap container is used to store and validate data input
to the to seqwrap.
}
\examples{
# swcontainer is the S7 class produced by seqwrap_compose(). End users
# normally build one via seqwrap_compose() rather than calling this
# constructor directly.

library(seqwrap)

dat <- simcounts(n_genes = 5)

container <- seqwrap_compose(
  modelfun = stats::lm,
  arguments = list(formula = y ~ x),
  data = dat$data,
  metadata = dat$metadata,
  samplename = "sample"
)

# The object returned by seqwrap_compose() is a swcontainer instance
S7::S7_inherits(container, swcontainer)

}
