Monthly Archives: May 2005

Creating shaded areas in R

May 12, 2005
Creating shaded areas in R

Sometimes we want to shade areas under a density on a graphic, for instance to illustrate a p-value or a region under the normal curve. Using the polygon() function from base R we can make graphics like the following one: How to do it First we have to plot the graphic of the function whose

Read more »

Search R-bloggers


Never miss an update!
Subscribe to R-bloggers to receive
e-mails with the latest R posts.
(You will not see this message again.)

Click here to close (This popup will not appear again)