From the course: SQL Server Machine Learning Services: R

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Solution: Create a pie chart

Solution: Create a pie chart

From the course: SQL Server Machine Learning Services: R

Start my 1-month free trial

Solution: Create a pie chart

(punchy electronic music) - [Instructor] I hope you had fun exploring the options that are available in R for generating a new chart type. Let's go ahead and walk through my process. I'm going to start at the documentation page, and look through the different arguments for the pie function. So, in order to use this, we just use the function pie, pie, open a parenthesis. We have different arguments inside that we can apply to change the different style of our pie chart. Then we close the parenthesis at the end. So, the arguments that we have available start here with x, and it says that x is a vector of non-negative numerical quantities, and the values in x are displayed as the areas of the pie slices. So, this is what's going to render the size of the different wedges that make up the pie. The labels argument are a list of character strings that will name the slices, so we'll use those to label the different wedges in…

Contents