% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/aided_chatgpt.R
\name{sub.range}
\alias{sub.range}
\title{Calculate the Range Difference of a Numeric Vector}
\usage{
sub.range(x)
}
\arguments{
\item{x}{A numeric vector for which the range difference is to be calculated.}
}
\value{
A numeric value representing the difference between the maximum and minimum values of the input vector.
        Returns `NA` if the input is empty or contains only `NA` values.
}
\description{
This function calculates the difference between the maximum and minimum values of a numeric vector.
}
\examples{
# Example with a numeric vector
numeric_vector <- c(1, 5, 3, 8, 2)
sub.range(numeric_vector)

# Example with missing values
sub.range(c(NA, 4, 7, NA, 10))

}
