# NOT RUN {
# Generate data for the example
set.seed(123L)
jobchange2 <- jobchange[sample(nrow(jobchange), size = 1000), ]
# Diagnose the data with missing_count using diagnose() function
library(dplyr)
jobchange2 %>%
diagnose %>%
arrange(desc(missing_count))
# Visualize pareto chart for variables with missing value.
plot_na_pareto(jobchange2)
# Visualize pareto chart for variables with missing value.
plot_na_pareto(jobchange2, col = "blue")
# Visualize only variables containing missing values
plot_na_pareto(jobchange2, only_na = TRUE)
# Display the relative frequency
plot_na_pareto(jobchange2, relative = TRUE)
# Change the grade
plot_na_pareto(jobchange2, grade = list(High = 0.1, Middle = 0.6, Low = 1))
# Change the main title.
plot_na_pareto(jobchange2, relative = TRUE, only_na = TRUE,
main = "Pareto Chart for jobchange")
# Return the aggregate information about missing values.
plot_na_pareto(jobchange2, only_na = TRUE, plot = FALSE)
# Not support typographic elements
plot_na_pareto(jobchange2, typographic = FALSE)
# }
Run the code above in your browser using DataLab