Skip to content

Automatic setting of breaks with probit scale #871

Closed

Description

@krlmlr

Automatic setting of breaks fails with probit scale if there are values
too close to 0 or 1.

Bug

qplot(c(0.25, 8), c(0.03, 0.95)) + scale_y_continuous(trans = "probit")
## Error: 'from' cannot be NA, NaN or infinite

Data-dependent: y values further away from 0 or 1 don't trigger it

qplot(c(0.25, 8), c(0.3, 0.7)) + scale_y_continuous(trans = "probit")

plot of chunk unnamed-chunk-3

Workaround: Set explicit breaks

qplot(c(0.25, 8), c(0.03, 0.95), data = soilSample) + scale_y_continuous(trans = "probit", 
    breaks = seq(0.2, 0.8, 0.2))

plot of chunk unnamed-chunk-4

Bug with explicit breaks

qplot(c(0.25, 8), c(0.03, 0.95)) + scale_y_continuous(trans = "probit", 
    breaks = seq(0, 1, 0.2))
## Error: 'from' cannot be NA, NaN or infinite

See also daqana/tikzDevice@9f381e6

Activity

  1. hadley commented on Feb 24, 2014

    @hadley
    Member

    This sounds like a great feature/horrible bug, but unfortunately we don't currently have the development bandwidth to support it/fix it. If you'd like to submit a pull request that implements this feature/fixes this bug, please follow the instructions in the development vignette.

  2. locked as resolved and limited conversation to collaborators on Jun 19, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions