pctCen | R Documentation |
pctCen
is a simple, but convenient, function that calculates
the percentage of censored values.
pctCen(obs, censored, na.action)
obs |
A numeric vector of observations. This includes both censored and uncensored observations. |
censored |
A logical vector indicating TRUE where an observation in v is censored (a less-than value) and FALSE otherwise. |
na.action |
A function which indicates what should happen
when the data contain |
100*(length(obs[censored])/length(obs))
pctCen
returns a single numeric value representing
the percentage of values censored in the “obs" vector.
R. Lopaka Lee <rclee@usgs.gov>
Dennis Helsel <dhelsel@practicalstats.com>
splitQual
, ros
,
obs = c(0.5, 0.5, 1.0, 1.5, 5.0, 10, 100)
censored = c(TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE)
pctCen(obs, censored)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.