Hi all.
I am trying to create a pie chart. The output percentages on the chart are wrong and do not correlate with the sizes of the slices - big slices are 18% and small ones are 65%, for example. Help with this would be really appreciated!
slices4 <- c(87242182, 21598297, 11635335, 4734527, 2633893, 1337270, 1977707)
lbls4 <- c("Deionised water production", "Wastewater Treatment", "KCl Production","Blasting","Other","Treatment of salt from potash mine","Remaining processes (<0.1%)")
pie(slices4, labels = "lbls4")
lbls4 <- paste(lbls4, pct) # add percents to labels
lbls4 <- paste(lbls4,"%",sep="") # ad % to labels
pie(slices4, col=c("#67001f", "#b2182b", "#d6604d", "#f4a582", "#fddbc7", "#d1e5f0", "#92c5de"),labels = lbls4)