Good morning
I have a problem with the next graphic, I cannot delete "NA" bar, in my graphic I need only 1960 $ 1970s. How I can remove this bar in te next code?
3a gap%>%
filter(region %in% c("Southern Europe", "South America", "Australia and New Zealand", "Western Asia", "Western Africa")) %>%
mutate(decade = case_when(between(year,1960,1969) ~ "1960s",
between(year,1970,1979) ~ "1970s")) %>%
ggplot(aes(x = factor(decade), y = gdp, fill = region)) +
geom_col(position = "fill") +
scale_fill_brewer(palette = 3, type = "qual") +
theme_minimal()
Itried to remove "NA" in data frame with the next code
gap<- na.omit(gap)
but, when I print the cade "NA" bar is on the grapic again