Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

Error when all data is outside limits of continuous scale #627

Closed
wch opened this Issue · 1 comment

2 participants

@wch
Collaborator

This is from the examples:

# OK
qplot(mpg, wt, data=mtcars) + ylim(0, 10)

# All data is outside y limits - Error
qplot(mpg, wt, data=mtcars) + ylim(10, 20)
# Error: Discrete value supplied to continuous scale
@hadley
Owner

I think this should be simple fix: make censor return NA_real_ instead of NA (which is logical, and hence counted as discrete). Even better you should return an NA of the same type as x - but I don't know an easy way of doing that.

@wch wch closed this in 404f72f
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.