% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/runELA.R
\name{bootstrap_ELA}
\alias{bootstrap_ELA}
\title{Energy landscape analysis with bootstrap resampled SA results}
\usage{
bootstrap_ELA(
  bs_params,
  ocmat,
  ela = NULL,
  env = NULL,
  enmat = NULL,
  threads = 1,
  reporting = FALSE
)
}
\arguments{
\item{bs_params}{output of \link{bootstrap_SA}. list of estimated parameters using bootstrap resampled data set.}

\item{ocmat}{community composition matrix.}

\item{ela}{representative ELA result (output of \link{ELA}). If \code{NULL}, the function returns the most representative one.}

\item{env}{target environmental factor.}

\item{enmat}{array of the vectors of environmental factors for each sample. Normalization required.}

\item{threads}{number of cores (threads) used for calculation.}

\item{reporting}{enable/disable the reporting function.}
}
\value{
A list with two elements:
  (1) representative pruned ELA result (stable states, energies, tipping points, tipping energies),
  (2) a data frame of bootstrap energies (rows = state IDs, columns = trials) with \code{NaN} for missing states.
}
\description{
Running energy landscape analysis with bootstrap sampling of estimated saresults

Performs \link{ELA} and \link{ELPruning} using SA fitting results based on 
the bootstrap resampled occurrence and environmental data using \link{bootstrap_SA}.

Basically, representative ELA results with original occurrence and environmental data should be given by \code{ela=ela},
alternatively the function can select a representative parameter where commonly appearing stable states are most frequent.

The function computes bootstrap energy distributions for all stable states and tipping points
appearing in the specified pruned landscape. Energies that are not present in a given trial
are stored as \code{NaN} in the summary table.
}
