Give regularly spaced points on interval n
and larger round.dig
). Note that n
.
unif(n, round.dig = 1 + trunc(log10(n)))
positive integer specifying the number of points desired.
integer indicating to how many digits the result is rounded.
numeric vector of length n
, symmetric around 0, hence
with exact mean 0
, and variance approximately 1.
runif
for producing uniform random numbers.
(u <- unif(8))
var(u)
(u. <- unif(8, 12))# more digits in result, hence precision for Var :
var(u.)
Run the code above in your browser using DataLab