% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/utils.R
\name{Formatting}
\alias{Formatting}
\title{Formatting}
\usage{
Formatting(
  baseabtable,
  basemetadata = NULL,
  normalize = 1,
  parameters = c(0.05, 0.05, 0.95),
  grouping = 0,
  grouping_th = 0,
  reporting = TRUE
)
}
\arguments{
\item{baseabtable}{Abundance table (samples x species) as data.frame/matrix.}

\item{basemetadata}{Optional environmental metadata table (samples x factors); NULL/empty for none.}

\item{normalize}{Integer 0 or 1. If 1, normalize within each sample to sum to 1.}

\item{parameters}{Numeric vector/list of thresholds (following 3 parameters).
1. "0/1 threshold"
2. "min occurrence threshold"
3. "max occurrence threshold"
(e.g., c(0.05, 0.05, 0.95) : species abundance > 0.05 is regarded as present,
and species occurring in more than 0.05 and less than 0.95 in the all samples are kept.)}

\item{grouping}{Integer 0 or 1. If 1, group similar occurrence patterns.}

\item{grouping_th}{Numeric threshold for grouping (relative Hamming distance).}

\item{reporting}{Logical. If TRUE, print processing summary.}
}
\value{
A list: (ocmatrix, abmatrix, fctmatrix, samplelabel, specieslabel, factorlabel).
}
\description{
Generate occurrence(binary)/abundance/factor matrices and labels from input abundance/metadata tables.
}
