par(mfrow= c(1,2)) curve(dnorm(x),from = -2,to =2 ) xx<-seq(-0.5,0.5,0.05) yy<-dnorm(xx) polygon(c(-0.5,xx,0.5),c(0,yy,0),col = "lightgrey") percent <- round((pnorm(0.5)-pnorm(-0.5))*100,digits = 1) text.percent <- paste(percent,"%",sep = "") text(0,0.2,text.percent) curve(dnorm(x),from = -2,to =2) xx<-seq(-1,0,0.05) yy<-dnorm(xx) polygon(c(-1,xx,0),c(0,yy,0),col = "lightgrey") percent <- round((pnorm(0)-pnorm(-1))*100,digits = 1) text.percent <- paste(percent,"%",sep = "") text(-.5,0.2,text.percent)