library(ggplot2)

Polygon

p <- ggplot(economics, aes(date, unemploy))
p <- p + geom_polygon()
print(p)

Rectangle

p <- ggplot(seals, aes(x <- long, y <- lat))
p <- p + geom_rect(
    aes(xmin = long, ymin = lat, xmax = long + 1, ymax = lat + 1)
)
print(p)