I\'m plotting a cdf of some data, and I\'ve added logarithmic scale on the \"x\" axis. The ticks spacing is exactly as I want it to be, but I\'d like to be able to add s
Considering the initial script, and the tips given by @BenBolker, I had to use:
axis(side = 1, at = c([all the ticks you want]))
in order to add the ticks
in the graph. Here's the final result:
# Cumulative Distribuition
pdf("g1_3.pdf")
plot(x = f$V2, y = cumsum(f$V1), log = "x", pch = 3,
xlab = "Frequency", ylab = "P(X <= x)", axes = FALSE)
ticks = c(1, 5, 10, 40, 150, 500, 1000)
axis(side = 1, at = ticks)
axis(side = 2)
abline(h = seq(0, 1, 0.2), v = ticks, col = "lightgray", lty = 3)
box()