Climate change and science has been an issue for discussion and debate for at least the last decade. Climate data collection is currently being collected for areas all over the world. Policy decisions are based on the most recent analysis conducted on data extracted from huge online repositories of this data. Due to the inherent growth in the electronic production and storage of information, there is often a feeling of “information overload” or inundation when facing the process of quantitative decision making. As an analyst your job will often be to explore large data sets and develop questions or ideas from visualizations of those data sets.
The ability to synthesize large data sets using visualizations is a skill that all data scientists should have. In addition to this data scientists are called upon to present data syntheses and develop questions or ideas based on their data exploration. This lab should take you through the major steps in data exploration and presentation.
The objective of this laboratory is to survey the available data, plan, design, and create an information dashboard/presentation that not only explores the data but helps you develop questions based on that data exploration. To accomplish this task you will have to complete a number of steps:
You are responsible for submitting a link to your dashboard hosted on the Rpubs site. The dashboard must include the source_code = embed parameter.
The due date for this project is XX at the start of class. This assignment is worth 75 points, 3x a normal homework, the additional time should allow you to spend the neccessary effort on this assignment.
You are welcome to work in groups of ≤2 people. However, each person in a group must submit their own link to the assignment on Canvas for grading! Each team member can submit the same link to a single rpubs account, however it may be a good idea for each of you to post your own copy to rpubs in case you want to share it to prospective employers.
Getting data There are lots of places we can get climate data to answer your questions. The simplest would be to go to NOAA National Centers for Environmental Information (https://www.ncdc.noaa.gov/). There are all kinds of data here (regional, global, marine). Also, on the front page of the NOAA website there are also other websites that have climate data, such as: (https://www.climate.gov/), (https://www.weather.gov/), (https://www.drought.gov/drought/), and (https://www.globalchange.gov/). Obviously, you don’t have to use all of them but it might be helpful to browse them to get ideas for the development of your questions.
Alternatively, and more professionally, there are tons of packages that allow you to access data from R. See here for a great primer on accessing NOAA data with ‘R’. It is also a good introduction to API keys and their use.
The map shows the minimum / maximum temperature across each state from 2017 to 2022 for a period of 60 months. Quick glance on the map shows that the south states have a higher max temperature than those in the north. Florida seems to have the highest and Minnoseta the lowest.
The map shows the statewide precipitation from 2017 to 2022 for a period of 60 months. In line with what we see with the precipitation, east has higher precipitation especial south east, the midlle and west lack of precipitation.
The Residential Energy Demand Temperature Index (REDTI) is based on population weighted heating and cooling degree days, and as such, is a valuable tool for explaining year-to-year fluctuations in energy demand for residential heating and cooling.
Above chart show the REDTI between 1900 to 2019. From the graph we can see that the energy demand temperature is gradually increassing over the periods. Based on the graph REDTI index has been increased almost 12 points in last 100 years. This finding also corelate with the annual national average temperture findings.
Finally, we are seeing the Snow and Ice cover from 1900 to the current year for the month of January as it is usually the coldest month. Though in the graph, the line looks steady, a closer observation shows the coverage is decreased a little. This could be due to the increase in temperatures.
Graph show the Sea Ice content of Northern Hemisphere. This graph shows the data between 1979 to 2019 of August month. We can see from the graph that Sea Ice is slowly decreasing over the time.
Is there a pattern in Annual National Temperature? Yes, Annual National Max Temperature has gradually increased over the time, Min temperature has gradually decrease over the time, the trends shows that the climate is becoming more extreme.
What is the maximum temperatures across each state in the last 5 years? The maximum temperatures across the states vary from 50 degrees to 85 degrees. The south states have a higher average temperature than those in the north. Florida seems to have the highest and Minnesota the lowest.
What is statewide precipitation indicate to? precipitation level will impact the stability of eco-system which affects the climate change.
Is there any correlation between Residential Energy Demand Temperature Index and the Annual National Temperature? Yes. There is a positive correlation. REDTI has also increased over the last century. May be because of the increasing temperature demand for Residential energy has increased.
Do we see a relationship between snow level and temperature? We see the snow cover varying on a per year basic in the last century similar to the maximum temperature. Also there is a minor decrease and therefore this could signify there is a relationship between snow level and temperatures.
Is there any correlation between increasing temperature and Northen Hemisphere sea ice extent? Yes, there is a negative correlation. It seems like increasing temperature causing a global worming effect which decreasing Sea Ice content in Northern Hemisphere.
---
title: "ANLY 512 - Lab 2"
author: "Gefei Yang"
date: "`r Sys.Date()`"
output:
flexdashboard::flex_dashboard:
storyboard: true
social: menu
source: embed
---
# Table of Contents {.sidebar}
* Introduction
* Overview
* Objective
* Dates & Deliverables
* Methods Help
* Observations
* Max/Min Temperature - All States
* Statewide Precipitation
* Residential Energy Trend
* Snow and Ice Cover
* Northern Hemisphere Sea Ice Extent
# **Introduction**
Row {data-height=230}
-------------------------------------
### **Overview**
Climate change and science has been an issue for discussion and debate for at least the last decade. Climate data collection is currently being collected for areas all over the world. Policy decisions are based on the most recent analysis conducted on data extracted from huge online repositories of this data. Due to the inherent growth in the electronic production and storage of information, there is often a feeling of “information overload” or inundation when facing the process of quantitative decision making. As an analyst your job will often be to explore large data sets and develop questions or ideas from visualizations of those data sets.
The ability to synthesize large data sets using visualizations is a skill that all data scientists should have. In addition to this data scientists are called upon to present data syntheses and develop questions or ideas based on their data exploration. This lab should take you through the major steps in data exploration and presentation.
Row
-------------------------------------
### **Objective**
The objective of this laboratory is to survey the available data, plan, design, and create an information dashboard/presentation that not only explores the data but helps you develop questions based on that data exploration. To accomplish this task you will have to complete a number of steps:
1. Identify what information interests you about climate change.
2. Find, collect, organize, and summarize the data necessary to create your data exploration plan.
3. Design and create the most appropriate visualizations (no less than 5 visualizations) to explore the data and present that information.
4. Finally organize the layout of those visualizations into a dashboard (use the flexdashboard package) in a way that shows your path of data exploration.
5. Develop four questions or ideas about climate change from your visualizations.
### **The Decision & Rules**
1. You are responsible for submitting a link to your dashboard hosted on the Rpubs site. The dashboard must include the source_code = embed parameter.
2. The due date for this project is XX at the start of class. This assignment is worth 75 points, 3x a normal homework, the additional time should allow you to spend the neccessary effort on this assignment.
3. You are welcome to work in groups of ≤2 people. However, each person in a group must submit their own link to the assignment on Canvas for grading! Each team member can submit the same link to a single rpubs account, however it may be a good idea for each of you to post your own copy to rpubs in case you want to share it to prospective employers.
### **Methods Help**
1. Getting data
There are lots of places we can get climate data to answer your questions. The simplest would be to go to NOAA National Centers for Environmental Information (https://www.ncdc.noaa.gov/). There are all kinds of data here (regional, global, marine). Also, on the front page of the NOAA website there are also other websites that have climate data, such as: (https://www.climate.gov/), (https://www.weather.gov/), (https://www.drought.gov/drought/), and (https://www.globalchange.gov/). Obviously, you don’t have to use all of them but it might be helpful to browse them to get ideas for the development of your questions.
2. Alternatively, and more professionally, there are tons of packages that allow you to access data from R. See here for a great primer on accessing NOAA data with ‘R’. It is also a good introduction to API keys and their use.
```{r setup, include=FALSE}
library(flexdashboard)
library(maps)
library(ggmap)
library(dplyr)
library(ggplot2)
library(maptools)
```
Max/Min Temperature - All States
=====================================
Row {data-height=20}
-------------------------------------
```{r,echo = FALSE, message = FALSE}
maxTempData <- read.csv(url("https://www.ncdc.noaa.gov/cag/statewide/mapping/110-tmax-202210-60.csv"),skip=3)
maxTempData$region = tolower(maxTempData$Location)
us_states = map_data("state")
maxTempData = merge(us_states, maxTempData, by="region", all=T)
ggplot(maxTempData, aes(x = long, y = lat, group = group, fill = Value)) +
geom_polygon(color = "white") +
scale_fill_gradient(name = "Degrees Fahrenheit", low = "#feceda", high = "#c81f49", guide = "colorbar", na.value="black") +
labs(title="Statewide Maximum Temperature [Oct 2017 - Oct 2022]", x="Longitude", y="Latitude")+
coord_map()
```
Min Temperature
=====================================
Row {data-height=20}
-------------------------------------
```{r}
minTempData = read.csv(url("https://www.ncdc.noaa.gov/cag/statewide/mapping/110-tmin-202210-60.csv"),skip=3)
minTempData$region = tolower(minTempData$Location)
minTempData = merge(us_states, minTempData, by="region", all=T)
ggplot(minTempData, aes(x = long, y = lat, group = group, fill = Value)) +
geom_polygon(color = "white") +
scale_fill_gradient(name = "Degrees Fahrenheit", na.value="black") +
labs(title="Statewide Minumum Temperature [Oct 2017 - Oct 2022] ", x="Longitude", y="Latitude")+
coord_map()
```
### **Summary**
The map shows the minimum / maximum temperature across each state from 2017 to 2022 for a period of 60 months. Quick glance on the map shows that the south states have a higher max temperature than those in the north. Florida seems to have the highest and Minnoseta the lowest.
Statewide Precipitation
=====================================
Row {data-height=20}
-------------------------------------
```{r,echo = FALSE, message = FALSE}
pcpData <- read.csv(url("https://www.ncei.noaa.gov/access/monitoring/climate-at-a-glance/statewide/mapping/110-pcp-202210-60.csv"),skip=3)
pcpData$region = tolower(pcpData$Location)
pcpData = merge(us_states, pcpData, by="region", all=T)
ggplot(pcpData, aes(x = long, y = lat, group = group, fill = Value)) +
geom_polygon(color = "white") +
scale_fill_gradient(name = "Precipitation", na.value="black", low = "Brown", high = "Green" ) +
labs(title="Statewide Precipitation [ Oct 2017 - Oct 2022] ", x="Longitude", y="Latitude")+
coord_map()
```
### **Summary**
The map shows the statewide precipitation from 2017 to 2022 for a period of 60 months. In line with what we see with the precipitation, east has higher precipitation especial south east, the midlle and west lack of precipitation.
Residential Energy Trend
=====================================
Row {data-height=20}
-------------------------------------
```{r}
REDTI_data = read.csv(url("https://www.ncdc.noaa.gov/societal-impacts/redti/USA/jun/1-month/data.csv"),skip=1)
ggplot(REDTI_data,aes(x=Date,y=REDTI)) +
geom_area(color = "black" ,fill = "gray")+
scale_y_continuous(limits = c(0, 100))+
geom_smooth(method='lm',se=FALSE)+
labs(title="Annual Residential Energy Demand Temperature Index [REDTI]",x="Year",y="REDTI")
```
### **Summary**
The Residential Energy Demand Temperature Index (REDTI) is based on population weighted heating and cooling degree days, and as such, is a valuable tool for explaining year-to-year fluctuations in energy demand for residential heating and cooling.
Above chart show the REDTI between 1900 to 2019. From the graph we can see that the energy demand temperature is gradually increassing over the periods. Based on the graph REDTI index has been increased almost 12 points in last 100 years. This finding also corelate with the annual national average temperture findings.
Snow and Ice Cover
=====================================
Row {data-height=20}
-------------------------------------
```{r,echo = FALSE, message = FALSE}
SnowCover = read.csv(url("https://www.ncdc.noaa.gov/snow-and-ice/extent/snow-cover/namgnld/1.csv"), skip=3)
ggplot(SnowCover,aes(x=Date,y=Value))+
geom_col()+
geom_smooth(method = 'lm')+
labs(title="Snow and Ice cover extent in North America and Greenland",x="Year",y="million square km")
```
### **Summary**
Finally, we are seeing the Snow and Ice cover from 1900 to the current year for the month of January as it is usually the coldest month. Though in the graph, the line looks steady, a closer observation shows the coverage is decreased a little. This could be due to the increase in temperatures.
Northern Hemisphere Sea Ice Extent
=====================================
Row {data-height=20}
-------------------------------------
```{r}
NHSI_data <- read.csv(url("https://www.ncdc.noaa.gov/snow-and-ice/extent/sea-ice/N/8.csv"),skip=3)
ggplot(NHSI_data,aes(x=Date,y=Value))+
geom_point(color = "brown")+
geom_smooth(method = 'lm', color = "tomato")+
labs(title="August Northern Hemisphere Sea Ice Extent (1979-2019)",x="Year",y="million square km")
```
### **Summary**
Graph show the Sea Ice content of Northern Hemisphere. This graph shows the data between 1979 to 2019 of August month. We can see from the graph that Sea Ice is slowly decreasing over the time.
Observation and Questions
=====================================
Row {data-height=20}
-------------------------------------
1. Is there a pattern in Annual National Temperature?
Yes, Annual National Max Temperature has gradually increased over the time, Min temperature has gradually decrease over the time, the trends shows that the climate is becoming more extreme.
2. What is the maximum temperatures across each state in the last 5 years? The maximum temperatures across the states vary from 50 degrees to 85 degrees. The south states have a higher average temperature than those in the north. Florida seems to have the highest and Minnesota the lowest.
3. What is statewide precipitation indicate to? precipitation level will impact the stability of eco-system which affects the climate change.
4. Is there any correlation between Residential Energy Demand Temperature Index and the Annual National Temperature?
Yes. There is a positive correlation. REDTI has also increased over the last century. May be because of the increasing temperature demand for Residential energy has increased.
5. Do we see a relationship between snow level and temperature?
We see the snow cover varying on a per year basic in the last century similar to the maximum temperature. Also there is a minor decrease and therefore this could signify there is a relationship between snow level and temperatures.
6. Is there any correlation between increasing temperature and Northen Hemisphere sea ice extent?
Yes, there is a negative correlation. It seems like increasing temperature causing a global worming effect which decreasing Sea Ice content in Northern Hemisphere.
References
=====================================
Row {data-height=20}
-------------------------------------
https://www.ncdc.noaa.gov/