DataExplorer icon indicating copy to clipboard operation
DataExplorer copied to clipboard

Color inconsistency in plot_missing

Open Quentin62 opened this issue 6 years ago • 1 comments

Hi, When you use plot_missing, colors associated with good, bad, OK, remove changed regarding the content of the data:

library(DataExplorer)

df <- data.frame(x = rnorm(100), y = rnorm(100), z = rnorm(100), a = rnorm(100), b = rnorm(100))

plot_missing(df)# good in red

image

df$x[1:4] = NA
df$z[91:100] = NA

plot_missing(df)# good in red, OK in blue

image

df$a[40:80] = NA

plot_missing(df)# good in green, bad in red, OK in an other blue

image

It would be more understandable to have a fixed color code.

Thanks

Quentin62 avatar Oct 07 '19 12:10 Quentin62

Thanks! I believe there is a work-around here: https://stackoverflow.com/a/55941266/2158269. Please use that while I come up with a more generic solution to colors.

boxuancui avatar Oct 07 '19 17:10 boxuancui