Ugly plot

Author

Amelia McNamara

# this is a comment that doesn't do anything
library(tidyverse)
library(readxl)
library(naniar)
library(janitor)
library(visdat)
name_stuff <- read_excel("MAVA Member Input Survey 2022 Results.xlsx",col_names = FALSE, n_max = 2)
name_stuff <- name_stuff %>%
  t() %>%
  as_tibble() %>%
  mutate(name = case_when(!is.na(V1) ~ V1,
                          !is.na(V2) ~ V2,
         TRUE ~ NA_character_))
MAVA <- read_excel("MAVA Member Input Survey 2022 Results.xlsx", skip = 3, col_names = FALSE)
names(MAVA) <- name_stuff$name
MAVA <- clean_names(MAVA)
ggplot(MAVA) + geom_bar(aes(x=gender_identity))
rename_with(MAVA, abbreviate, minlength = 15, everything()) %>%
  vis_miss(cluster = TRUE) 
ggplot(MAVA) + 
  geom_bar(aes(x=gender_identity, fill = gender_identity)) +
  theme_classic() +
  scale_fill_manual(values = c("red", "#FF0088", "lightgreen", "black", "mauve")) +
  theme(
    panel.grid.major = element_line(colour = "red", linewidth = 1, lineend = "round"),
    panel.grid.minor = element_line(colour = "red", linetype = "dashed", size = 0.2),
    panel.background = element_rect(fill = "lightblue"),
   # panel.border = element_rect(colour = "blue", fill = NA, size = 2)
    legend.background = element_rect(fill = "grey85", colour = "red", size = 1),
    legend.title = element_text(colour = "blue", face = "bold", size = 14),
    legend.text = element_text(colour = "red"),
    legend.key = element_rect(colour = "blue", size = 0.02)
  )
MAVA <- MAVA %>%
  dplyr::rename(welcome = do_you_feel_welcomed_and_included_in_all_mava_communications_and_services_ex_training_workshops_conferences_and_networking_events)

MAVA_test <- MAVA %>%
  drop_na(welcome) %>%
  group_by(gender_identity, welcome) %>%
  summarize(n = n()) %>%
  mutate(prop = n/sum(n)*100)

MAVA_test <- MAVA_test %>%
  select(-n) %>%
  pivot_wider(names_from = welcome, values_from = prop, values_fill = 0)

MAVA_test <- MAVA_test %>%
  rename(Item = gender_identity)

test2 <- likert(Item~., data.frame(MAVA_test), nlevels = 5)
plot(test2)