% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/plot_hsa.R
\name{plot_hsa}
\alias{plot_hsa}
\title{Visualize the stability of hespdiv polygons}
\usage{
plot_hsa(
  obj,
  alpha = 0.6,
  split.col = "gray20",
  pnts.col = NULL,
  pol.col = "7",
  type = 1,
  basal.col = 2,
  max.lwd = 3,
  min.lwd = 0.5,
  split.col.seed = NULL,
  newplot = TRUE,
  seperated = TRUE
)
}
\arguments{
\item{obj}{An object of class \code{hsa}}

\item{alpha}{The alpha value for transparency of split lines. Default is 0.6.}

\item{split.col}{Color of alternative subdivision split-lines. Default is "gray20".}

\item{pnts.col}{The color of data points. Default is NULL.}

\item{pol.col}{The color of polygons. Default is "7".}

\item{type}{An integer indicating the type of plot. Default is 1.}

\item{basal.col}{The color of basal subdivision split-lines.}

\item{max.lwd}{The maximum line width for split-lines. Default is 3.}

\item{min.lwd}{The minimum line width for split-lines. Default is 0.5.}

\item{split.col.seed}{A seed for generating random colors for split lines. Default is NULL.}

\item{newplot}{Create a plot in new device?}

\item{seperated}{Boolean. When \code{type} is >= 3, open a new graphical device for each rank?}
}
\value{
No return value, called for plotting sensitivity analysis results.
}
\description{
The function uses hespdiv sensitivity analysis results to visually
demonstrate the stability of the basal hespdiv subdivision. This is achieved
by displaying both alternative and basal hespdiv subdivisions on the same plot.
}
\details{
The \code{type} parameter determines the type of plot generated:
\describe{
\item{\code{1}}{
Basic plot: displays the alternative and basal hespdiv subdivisions on
the same plot without split-line ranks or titles.
}

\item{\code{2}}{
Plot with split-line ranks: includes split-line ranks in the plot.
Each split-line is assigned a different line width based on its rank.
}

\item{\code{3}}{
Plot with separate ranks: generates multiple plots, each representing
split-line ranks up to a certain value.
}

\item{\code{4}}{
Plot with separate and isolated ranks: similar to mode 3 but isolates
split-line ranks. Generates multiple plots, each representing a
specific split-line rank.
}
}

If the alternative subdivisions spatially converge but the basal
subdivision lies far from the zone of convergence, you can use
\code{change_base} to select a more representative alternative
subdivision to serve as the basal subdivision. However, you should
verify that the arguments used in that subdivision are appropriate.
}
\note{
\code{newplot} allows the legend to be rendered correctly in
types 2 and 3, and helps with line rendering in general when drawing
in an active device (use \code{broom} otherwise to delete devices).
}
\seealso{
Other functions for hespdiv sensitivity analysis: 
\code{\link{change_base}()},
\code{\link{hsa}()},
\code{\link{hsa_detailed}()},
\code{\link{hsa_quant}()},
\code{\link{hsa_sample_constrained}()},
\code{\link{plot_cs_hsa}()},
\code{\link{plot_hsa_q}()}

Other HespDiv visualization options: 
\code{\link{blok3d}()},
\code{\link{create_gif}()},
\code{\link{dendro}()},
\code{\link{plot.nullhespdiv}()},
\code{\link{plot_cs_hsa}()},
\code{\link{plot_hespdiv}()},
\code{\link{plot_hsa_q}()},
\code{\link{poly_scheme}()},
\code{\link{polypop}()}
}
\author{
Liudas Daumantas
}
\concept{HespDiv visualization options}
\concept{functions for hespdiv sensitivity analysis}
