According to Plotting CCDF of walking durations, I generated the ccdf plot like this:
ccdf<-function(views,density=FALSE)
{
freq = table(views)
X = rev(as.numeric(names(freq)))
Y =cumsum(rev(as.list(freq)));
data.frame(x=X,count=Y)
}
library(ggplot2)
qplot(x,count,data=ccdf(views),log='xy')
The Y axis = counts of x value, but I want to get the Y = P[X >= x], how can I do that?