I’m trying to plot a pie chart using plotly package. this is my data frame.
Dept value
1 A 31
2 B 21
3 C 12
4 D 15
5 E 7
6 F 14
For some reason it appears empty in Viewer with no errors. I’ve tried every variation but to no avail. This is what I wrote: > plot_ly(all_male) %>% add_pie(all_male, labels= ~Dept
, values=~value
)
New contributor
Laju Eribo is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.