Initial Commit with Project Code
This commit is contained in:
Binary file not shown.
|
After Width: | Height: | Size: 166 KiB |
@@ -0,0 +1,268 @@
|
||||
Lesson 4
|
||||
========================================================
|
||||
|
||||
***
|
||||
|
||||
### Scatterplots and Perceived Audience Size
|
||||
Notes:
|
||||
|
||||
***
|
||||
|
||||
### Scatterplots
|
||||
Notes:
|
||||
|
||||
```{r Scatterplots}
|
||||
|
||||
```
|
||||
|
||||
***
|
||||
|
||||
#### What are some things that you notice right away?
|
||||
Response:
|
||||
|
||||
***
|
||||
|
||||
### ggplot Syntax
|
||||
Notes:
|
||||
|
||||
```{r ggplot Syntax}
|
||||
|
||||
```
|
||||
|
||||
***
|
||||
|
||||
### Overplotting
|
||||
Notes:
|
||||
|
||||
```{r Overplotting}
|
||||
|
||||
```
|
||||
|
||||
#### What do you notice in the plot?
|
||||
Response:
|
||||
|
||||
***
|
||||
|
||||
### Coord_trans()
|
||||
Notes:
|
||||
|
||||
```{r Coord_trans()}
|
||||
|
||||
```
|
||||
|
||||
#### Look up the documentation for coord_trans() and add a layer to the plot that transforms friend_count using the square root function. Create your plot!
|
||||
|
||||
```{r}
|
||||
|
||||
```
|
||||
|
||||
#### What do you notice?
|
||||
|
||||
***
|
||||
|
||||
### Alpha and Jitter
|
||||
Notes:
|
||||
|
||||
```{r Alpha and Jitter}
|
||||
|
||||
```
|
||||
|
||||
***
|
||||
|
||||
### Overplotting and Domain Knowledge
|
||||
Notes:
|
||||
|
||||
***
|
||||
|
||||
### Conditional Means
|
||||
Notes:
|
||||
|
||||
```{r Conditional Means}
|
||||
|
||||
```
|
||||
|
||||
Create your plot!
|
||||
|
||||
```{r Conditional Means Plot}
|
||||
|
||||
```
|
||||
|
||||
***
|
||||
|
||||
### Overlaying Summaries with Raw Data
|
||||
Notes:
|
||||
|
||||
```{r Overlaying Summaries with Raw Data}
|
||||
|
||||
```
|
||||
|
||||
#### What are some of your observations of the plot?
|
||||
Response:
|
||||
|
||||
***
|
||||
|
||||
### Moira: Histogram Summary and Scatterplot
|
||||
See the Instructor Notes of this video to download Moira's paper on perceived audience size and to see the final plot.
|
||||
|
||||
Notes:
|
||||
|
||||
***
|
||||
|
||||
### Correlation
|
||||
Notes:
|
||||
|
||||
```{r Correlation}
|
||||
|
||||
```
|
||||
|
||||
Look up the documentation for the cor.test function.
|
||||
|
||||
What's the correlation between age and friend count? Round to three decimal places.
|
||||
Response:
|
||||
|
||||
***
|
||||
|
||||
### Correlation on Subsets
|
||||
Notes:
|
||||
|
||||
```{r Correlation on Subsets}
|
||||
with( , cor.test(age, friend_count))
|
||||
```
|
||||
|
||||
***
|
||||
|
||||
### Correlation Methods
|
||||
Notes:
|
||||
|
||||
***
|
||||
|
||||
## Create Scatterplots
|
||||
Notes:
|
||||
|
||||
```{r}
|
||||
|
||||
```
|
||||
|
||||
***
|
||||
|
||||
### Strong Correlations
|
||||
Notes:
|
||||
|
||||
```{r Strong Correlations}
|
||||
|
||||
```
|
||||
|
||||
What's the correlation betwen the two variables? Include the top 5% of values for the variable in the calculation and round to 3 decimal places.
|
||||
|
||||
```{r Correlation Calcuation}
|
||||
|
||||
```
|
||||
|
||||
Response:
|
||||
|
||||
***
|
||||
|
||||
### Moira on Correlation
|
||||
Notes:
|
||||
|
||||
***
|
||||
|
||||
### More Caution with Correlation
|
||||
Notes:
|
||||
|
||||
```{r More Caution With Correlation}
|
||||
install.packages('alr3')
|
||||
library(alr3)
|
||||
```
|
||||
|
||||
Create your plot!
|
||||
|
||||
```{r Temp vs Month}
|
||||
|
||||
```
|
||||
|
||||
***
|
||||
|
||||
### Noisy Scatterplots
|
||||
a. Take a guess for the correlation coefficient for the scatterplot.
|
||||
|
||||
b. What is the actual correlation of the two variables?
|
||||
(Round to the thousandths place)
|
||||
|
||||
```{r Noisy Scatterplots}
|
||||
|
||||
```
|
||||
|
||||
***
|
||||
|
||||
### Making Sense of Data
|
||||
Notes:
|
||||
|
||||
```{r Making Sense of Data}
|
||||
|
||||
```
|
||||
|
||||
***
|
||||
|
||||
### A New Perspective
|
||||
|
||||
What do you notice?
|
||||
Response:
|
||||
|
||||
Watch the solution video and check out the Instructor Notes!
|
||||
Notes:
|
||||
|
||||
***
|
||||
|
||||
### Understanding Noise: Age to Age Months
|
||||
Notes:
|
||||
|
||||
```{r Understanding Noise: Age to Age Months}
|
||||
|
||||
```
|
||||
|
||||
***
|
||||
|
||||
### Age with Months Means
|
||||
|
||||
```{r Age with Months Means}
|
||||
|
||||
```
|
||||
|
||||
Programming Assignment
|
||||
```{r Programming Assignment}
|
||||
|
||||
```
|
||||
|
||||
***
|
||||
|
||||
### Noise in Conditional Means
|
||||
|
||||
```{r Noise in Conditional Means}
|
||||
|
||||
```
|
||||
|
||||
***
|
||||
|
||||
### Smoothing Conditional Means
|
||||
Notes:
|
||||
|
||||
```{r Smoothing Conditional Means}
|
||||
|
||||
```
|
||||
|
||||
***
|
||||
|
||||
### Which Plot to Choose?
|
||||
Notes:
|
||||
|
||||
***
|
||||
|
||||
### Analyzing Two Variables
|
||||
Reflection:
|
||||
|
||||
***
|
||||
|
||||
Click **KnitHTML** to see all of your hard work and to have an html
|
||||
page of this lesson, your answers, and your notes!
|
||||
|
||||
Reference in New Issue
Block a user