I have plotted some data and now I would like to edit the legend. It should no longer have color as title but " Kategorie:" and the content of the legend should also not be 1,2,3... but "weiche Begriffe", "Extremismus", "Demagogie", "Verschwörungen", "Beleidigungen" and "Sexismus". I have already tried the command "scale_fill_discrete", but it just doesn't work. Does anyone have a solution?
ggplot(tabelle, aes(x = Monat)) +
geom_line(aes(y = weiche_Begriffe, color = "1"), linetype = 1, size =2) +
geom_line(aes(y = Extremismus, color = "2"), linetype = 1, size =2) +
geom_line(aes(y = Demagogie, color = "3"), linetype = 1, size =2)+
geom_line(aes(y = Verschwörung, color = "4"), linetype = 1, size =2)+
geom_line(aes(y = Beleidigung, color = "5"), linetype = 1, size =2)+
geom_line(aes(y = Sexismus, color = "6"), linetype = 1, size =2)+
labs(y = "Häufigkeit", title = "Häufigkeiten pro Monat")+
scale_x_continuous(breaks = seq(1,12, by = 1))