-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathHW5.Rmd
More file actions
37 lines (29 loc) · 1.08 KB
/
HW5.Rmd
File metadata and controls
37 lines (29 loc) · 1.08 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
---
title: "HW5-Q2"
author: "Jeremy Jarzab"
date: "3/18/2022"
output: html_document
---
```{r setup, include=FALSE}
knitr::opts_chunk$set(echo = TRUE)
```
## R Markdown
This is an R Markdown document. Markdown is a simple formatting syntax for authoring HTML, PDF, and MS Word documents. For more details on using R Markdown see <http://rmarkdown.rstudio.com>.
When you click the **Knit** button a document will be generated that includes both content as well as the output of any embedded R code chunks within the document. You can embed an R code chunk like this:
```{r}
library(maps)
library(mapdata)
library(ggplot2)
library(rmarkdown)
library(dplyr)
#2(a)
states <- map_data('state')
california <- states %>% filter(region == 'california')
#2(b)
load('D:/Users/Jeremy/Desktop/Online_Assignments/Winter 2022/CSC 302/wind_turbines.rda')
wind_ca <- wind_turbines %>% filter(t_state == 'CA')
#2(c) - 2(d)
ggplot(california, aes(long, lat)) +
geom_polygon(aes(group=group, fill=group), show.legend = FALSE) +
geom_point(data=wind_ca, aes(x=xlong, y=ylat))
```