% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/PMutilities.R
\name{round2}
\alias{round2}
\title{Round to x digits}
\usage{
round2(x, digits = getPMoptions("digits"))
}
\arguments{
\item{x}{A numeric value to be rounded.}

\item{digits}{The number of digits to round to. Default is set using \link{setPMoptions}.}
}
\value{
A character string representing the rounded value with the specified number of digits.
}
\description{
\ifelse{html}{\href{https://lifecycle.r-lib.org/articles/stages.html#stable}{\figure{lifecycle-stable.svg}{options: alt='[Stable]'}}}{\strong{[Stable]}}
Rounds a numeric value to a specified number of digits for display in flextables and plots.
}
\details{
Uses \link[base:format]{base::format} and \link[base:round]{base::round} to round a numeric value to a specified number of digits.
}
\keyword{internal}
