% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/hexagon_tiling.R
\name{cv_hex}
\alias{cv_hex}
\title{Hexagon tiling of region}
\usage{
cv_hex(samplers, cellsize = 0.5, n_group = 3, ...)
}
\arguments{
\item{samplers}{A sf object containing region for which
partitions to be created}

\item{cellsize}{hexagon cellsize, see \code{\link[sf:st_make_grid]{sf::st_make_grid()}} description}

\item{n_group}{number of cv folds.}

\item{\dots}{Passed on to \code{fm_nonconvex_hull()}, e.g. \code{resolution}}
}
\value{
a hexagonal partition covering the \code{samplers} object, with a \code{group}
integer variable indicating the fold assignment, 1, 2, ..., \code{n_group}.
}
\description{
\ifelse{html}{\href{https://lifecycle.r-lib.org/articles/stages.html#experimental}{\figure{lifecycle-experimental.svg}{options: alt='[Experimental]'}}}{\strong{[Experimental]}} Both the interface and function name
may change in future versions.

Partitions the region based on the hexagon tiling

Input:
}
\examples{
if (interactive()) {
  bnd <- gorillas_sf$boundary
  hex_cv <- cv_hex(bnd, cellsize = 0.5, n_group = 3, resolution = 100)
  plot(hex_cv)

  chess <- cv_partition(bnd, resolution = 0.5, chess = TRUE)
  plot(chess$white)
}

}
\author{
Man Ho Suen
}
\keyword{internal}
