In our last post on Getting Started with Data Visualizations in R, we went over how to start using ggplot2
in R. We learned how to set up a basic scatterplot and how to change the colors of the points via a variety of methods. We also learned how to update our plot for categorical variables, and how to add labels, change fonts, and alter the legend.
Have you ever wondered how to make colorful and interesting plots and charts for data visualization? Today’s post is Part 1 of a two-part series on getting started with data visualizations in R! Throughout this tutorial, we’ll be using ggplot2, a very useful R package that we can use to make some really great and professional-looking plots and figures for visualizing data.
In our last post, we approximated the mathematical constant \(\pi\) with simulated dart throwing in R. We also saw that, in general, as we increased the number of darts we threw, our estimate for \(\pi\) generally became more accurate. In this post, we'll see how can we can perform uncertainty quantification with the Central Limit Theorem for our \(\pi\) estimate. We’ll refer to the estimate that we compute for \(\pi\) as \(\hat{\pi}\).
Now that we’ve had several posts on getting started with coding in R (see Part 1, Part 2, and More Resources) we’re ready to get started with our first Code Lab! In this post, we’ll see how we can estimate pi with dart throwing in R!
Now that we’ve had several posts on getting started with coding in R (see Part 1, Part 2, and More Resources) we’re ready to get started with our first Code Lab! In this post, we’ll see how we can estimate pi with dart throwing in R!