R GraphicsLesson 27Free preview
R Pie Charts
This lesson is part of R · All levels
Summary
This lesson discusses the creation of a pie chart in R using the function pie(). A circular diagram is used to show the percentage proportion of complementary categories to the total 100%. The developer will learn to set up the percentage labels, play the initial orientation, and select the color palette.
Key points
- The 'pie(vektor_nilai, labels = vektor_label)' function creates a circular diagram
- The col argument stains every piece of the circumference of the circle
- The 'init.angle' argument determines the starting angle of the cutting diagram
- Although popular, pie charts should be limited to small categories so as not to be difficult to distinguish.
Full lesson
Code examples and quizzes
Full lessons, code examples, and quizzes are available to subscribers. 5 questions.