For example if i need to shade two area in plot
x<-rep(1:10)
plot(x,type="h")
I need as an example shade the area from 1 to 3 and from 7 to 10,
I use this commands but it omitted the lines of plot.
usr <- par('usr')
rect(1, usr[3], 3, usr[4], col='green')