I need to plot a pie chart as below: it must be colored by the same color but with scaled intensity.
Then In my case of use, I have this data frame :
library(ggplot2)
régions<-c("Bouches-du-Rhône","Paris","Nord","Hauts-de-Seine",
"Circonscription départementale du Rhône","Haute-Garonne","Bas-Rhin","Loire-Atlantique",
"Seine-Maritime","Pas-de-Calais")
Pourcentages<-c(15.2,15.2,12.3,10.1,9.7,8.4,7.7,7.5,7.2,6.8)
length(Pourcentages)
Data<-data.frame(régions,Pourcentages)
And as given here, I tried to plot my pie chart as given below.
bp<- ggplot(data, aes(x="", y=Pourcentages, fill=régions))+
geom_bar(width = 1, stat = "identity")
pie <- bp + coord_polar("y", start=0)
pie + scale_fill_brewer("Blues") + blank_theme+
theme(axis.text.x=element_blank())+
geom_text(aes( y=Pourcentages,
label = Pourcentages, size=5))
But I get this error that I can't resolve it:
Error: object 'blank_theme' not found
What should I do, please?


Error: object 'theme_blank' not found- Rprogrammerblank_themeanywhere? If not, you can't call something that hasn't been defined. But you're asking about both the theme and the coloring of the plot—these are separate issues handled by separate functions. Which are you really trying to address? - camille