add additional functions
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,23 @@
|
||||
% Generated by roxygen2: do not edit by hand
|
||||
% Please edit documentation in R/utils.R
|
||||
\name{perturb_count}
|
||||
\alias{perturb_count}
|
||||
\title{Add a random jitter to a count variable to mask its true value}
|
||||
\usage{
|
||||
perturb_count(x, fac = 3)
|
||||
}
|
||||
\arguments{
|
||||
\item{x}{the vector of numerics}
|
||||
|
||||
\item{fac}{the range of values to add or subtract to perturb the count}
|
||||
}
|
||||
\description{
|
||||
Add a random jitter to a count variable to mask its true value
|
||||
}
|
||||
\details{
|
||||
The count in the name means that this function enforces a floor of
|
||||
0 on values, so values perturbed to have less than 0 will be capped at 0.
|
||||
}
|
||||
\examples{
|
||||
perturb_count(20:30, fac = 3)
|
||||
}
|
||||
Reference in New Issue
Block a user