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

colourblind palette shows false NA values #55

Open
njtierney opened this issue Aug 29, 2017 · 1 comment
Open

colourblind palette shows false NA values #55

njtierney opened this issue Aug 29, 2017 · 1 comment

Comments

@njtierney
Copy link
Collaborator

When using palette = "cb_safe" in vis_dat, it shows missing values where there are none

library(visdat)
library(naniar)
library(tidyverse)
#> Loading tidyverse: ggplot2
#> Loading tidyverse: tibble
#> Loading tidyverse: tidyr
#> Loading tidyverse: readr
#> Loading tidyverse: purrr
#> Loading tidyverse: dplyr
#> Conflicts with tidy packages ----------------------------------------------
#> filter(): dplyr, stats
#> lag():    dplyr, stats

# shows missing values where there are none
pedestrian %>% 
  filter(month=="January", 
         year==2016) %>%
  vis_dat(palette = "cb_safe") +
  theme(aspect.ratio=1)

But if you use regular vis_dat, then there are no missing values shown.

# missing values not shown
pedestrian %>% 
  filter(month=="January", 
         year==2016) %>%
  vis_dat() +
  theme(aspect.ratio=1)

Need to dig into what happens here.

Thanks @dicook for pointing this out!

@njtierney njtierney added this to the V0.6.0 milestone Jun 6, 2018
@njtierney njtierney removed the V0.6.0 label Jun 6, 2018
@njtierney njtierney modified the milestones: V0.6.0, 0.5.4 Oct 14, 2022
@njtierney
Copy link
Collaborator Author

Consider using the colorspace R package to resolve this issue

@njtierney njtierney modified the milestones: 0.5.4, V0.6.0 Feb 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant