Helper function used to sample from a truncated normal distribution.
Usage
rnorm_trunc(n, range, mu, sigma)
Arguments
- n
Integer value specifying the number of samples.
- range
Vector with two values specifying the truncated range (lower bound and upper bound).
- mu
Number specifying the mean of the normal distribution.
- sigma
Number specifying the standard deviation of the normal distribution.
Value
Sample values from the truncated normal distribution.