add rounding utilities
Gitea Organization/civilyticsR/pipeline/head There was a failure building this commit
Gitea Organization/civilyticsR/pipeline/head There was a failure building this commit
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
% Generated by roxygen2: do not edit by hand
|
||||
% Please edit documentation in R/utils.R
|
||||
\name{trim_max}
|
||||
\alias{trim_max}
|
||||
\title{Take the maximum of a number after trimming values}
|
||||
\usage{
|
||||
trim_max(vec, n)
|
||||
}
|
||||
\arguments{
|
||||
\item{vec}{a numeric vector}
|
||||
|
||||
\item{n}{integer, the number of maximum values to trim before taking the maximum}
|
||||
}
|
||||
\value{
|
||||
the highest value after removing the highest n values
|
||||
}
|
||||
\description{
|
||||
Take the maximum of a number after trimming values
|
||||
}
|
||||
\examples{
|
||||
trim_max(c(10, 10, 10, 9, 8, 7), n = 2)
|
||||
trim_max(c(10, 10, 10, 9, 8, 7), n = 3)
|
||||
trim_max(c(10, 10, 10, 9, 8, 7), n = 4)
|
||||
}
|
||||
Reference in New Issue
Block a user