Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

vis_miss fails with single column of numbers #72

Closed
sfirke opened this Issue Mar 28, 2018 · 3 comments

Comments

Projects
2 participants
@sfirke
Copy link

sfirke commented Mar 28, 2018

x <- data.frame(a = 1:1000)
vis_miss(x)

Error in if (zero_range(from) || zero_range(to)) { :
missing value where TRUE/FALSE needed

@njtierney njtierney added the bug label Mar 29, 2018

@njtierney

This comment has been minimized.

Copy link
Collaborator

njtierney commented Mar 29, 2018

Heya Sam,

Thank you for posting this!

It looks like this is happening around line 156 of vis_miss - I'll have a look in the next week.

@njtierney njtierney added this to Priority in CRAN 5.0 release Apr 5, 2018

@njtierney njtierney added the V0.5.0 label Jun 4, 2018

@njtierney njtierney added this to the V0.2.0 milestone Jun 5, 2018

@njtierney njtierney removed the V0.5.0 label Jun 6, 2018

@njtierney

This comment has been minimized.

Copy link
Collaborator

njtierney commented Jun 6, 2018

Just to confirm here, this is a problem with single columns only - weird!

x <- data.frame(a = 1:1000)
y <- data.frame(a = c(1:1000, rep(NA, 100)))
z <- data.frame(a = c(1:1000, rep(NA, 100)),
                b = c(rep(NA, 100), 1:1000))

library(visdat)
vis_miss(x)
#> Error in if (zero_range(from) || zero_range(to)) {: missing value where TRUE/FALSE needed
vis_miss(y)
#> Error in if (zero_range(from) || zero_range(to)) {: missing value where TRUE/FALSE needed
vis_miss(z)

Created on 2018-06-07 by the reprex package (v0.2.0).

@njtierney njtierney closed this in c6e677a Jun 7, 2018

@njtierney

This comment has been minimized.

Copy link
Collaborator

njtierney commented Jun 7, 2018

Here is the current behaviour:

x <- data.frame(a = 1:1000)
y <- data.frame(a = c(1:1000, rep(NA, 100)))
z <- data.frame(a = c(1:1000, rep(NA, 100)),
                b = c(rep(NA, 100), 1:1000))

library(visdat)
vis_miss(x)

vis_miss(y)

vis_miss(z)

Created on 2018-06-07 by the reprex package (v0.2.0).

Thanks for posting this issue @sfirke :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.