I am trying to create the following chart in ggplot2, but I require it to be a horizontal graph, not a vertical one. I also require that the schedule be thin.
ggplot(Compositiondata, aes(x=1, y=`Composition`, fill=`Elements`),labels = FALSE) + geom_bar(stat="identity",aes(col.axis = "white",labels=FALSE)) + ggtitle("Title") + theme(axis.line=element_blank(), axis.text.x=element_blank(), axis.ticks.x=element_blank(), axis.title.x=element_blank(), panel.background=element_blank(), panel.border=element_blank(), panel.grid.major=element_blank(), panel.grid.minor=element_blank(), plot.background=element_blank()) + coord_fixed(ratio = 0.05) +coord_flip()
When I apply coord_flip() , the chart returns to its original width. How can I flip the chart and keep a small width?
source share