xlim {ggplot2}R Documentation

Set x limits

Description

Convenience function to set the limits of the x axis.

Usage

xlim(...)

Arguments

...

if numeric, will create a continuos scale, if factor or character, will create a discrete scale

limits

Author(s)

Hadley Wickham <h.wickham@gmail.com>

Examples

xlim(15, 20)
xlim(20, 15)
xlim(c(10, 20))
xlim("a", "b", "c") 
qplot(mpg, wt, data=mtcars) + xlim(15, 20)

[Package ggplot2 version 0.8.9 Index]