% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/index_on_grid.r
\name{index_on_grid}
\alias{index_on_grid}
\title{Generating maps of indexes}
\usage{
index_on_grid(
  mTATBsp,
  stratum,
  wd = NA,
  map_range,
  threshold = 30,
  verbose = FALSE,
  save = TRUE
)
}
\arguments{
\item{mTATBsp}{spatial mTATB}

\item{stratum}{reference stratum range (allowed values: "10,200","10,800","200,800","5,35","5,45")}

\item{wd}{working directory}

\item{map_range}{range of coordinates for the map}

\item{threshold}{minimum number of individuals per haul}

\item{verbose}{boolean. If TRUE messages are promted in the console}

\item{save}{boolean. If TRUE the results are stored in the working directory}
}
\value{
A \code{ggplot} object displaying the generated map of indices on the spatial grid.
}
\description{
Generates density and biomass maps based on the spatial grid,
allowing for the visual identification of resource concentration areas
or potential biological hotspots.
}
\examples{
data(TA)
data(TB)
data(TC)
m <- merge_TATBTC(TA[TA$AREA == 10, ], TB[TB$AREA == 10, ], TC[TC$AREA == 10, ],
                  species = "MERLMER", country = "all", verbose = FALSE)
mTATBsp <- overlayGrid(m[[1]], m[[2]], GSA = 10, save = FALSE, verbose = FALSE)[[1]]
map_range <- c(9, 15, 39, 42)
index_on_grid(mTATBsp, stratum = "10,800", map_range = map_range, threshold = 5,
              save = FALSE, verbose = FALSE)
}
