mean(x, ...)
"mean"(x, trim = 0, na.rm = FALSE, ...)
trim = 0
, only.x
before the mean is computed.
Values of trim outside that range are taken as the nearest endpoint.
NA
values should be stripped before the computation proceeds.weighted.mean
, mean.POSIXct
,
colMeans
for row and column means.
x <- c(0:10, 50)
xm <- mean(x)
c(xm, mean(x, trim = 0.10))
Run the code above in your browser using DataLab