# data[].attributes.body
ggplot(pm_data, aes(x = imp_a15000, y = popdens_county,)) +

geom_point(color = "#798645", size = 2, alpha = 0.4) +

labs(

title = "Scatter Plot of Population Density vs. Impervious Surface",

y = "Population Density (people per km² in county)",

x = "Impervious Surface Measure (within 15000m)"

) +

theme_minimal() +

theme(

plot.title = element_text(hjust = 0.5, face = "bold"),

legend.text = element_text(size = 10, family = "Rubik")

)

# data[].attributes.body
ZCTA has a postive correlation

zcta_pop and popdens_zcta have negative correlations

population density isn’t always directly proportional to area size

# data[].attributes.headline
emissions and population density by zipcode

# data[].attributes.subject
emissions and population density by zipcode

# data[].attributes.body
in the above graphs, i tried making scatterplots to vizualize correlation between population density and emissions

# data[].attributes.body
For lab 6, I created a boxplot to look at which states had higher PM values, and to show the variance between states. One interesting thing I found was that there was a lot of variability in observations specifically for California. I also found that Maine and Wyoming had lower PM values compared to other states so I think it would be interesting to look into this in relation to road density and industries present in those states.

# data[].attributes.body
super colorful graph! overall positive linear relationship between population density and measured emissions within radial distance.

# data[].attributes.body
1. After taking log function, correlations between variables became more significant. For example, log_popdens_county column appears to show some correlation.

2. Variables now have a more unified matrix(from 0 - 60 instead of from 0 to 60000)

3. There are outliers for log_pri_length.

# data[].attributes.body
I wanted to see if Education is correlated/associated with Road length in any way. I also used a stigmatized knowledge where low education level and poverty is correlated with a low income community (I know, wrong to assume, but I come from said community, so cut me some slack) and wanted to see the road length within these communities. From there perhaps we can make some inferences on air pollution.

# data[].attributes.headline
There is a weak positive correlation between the imp_a500 variable and the target value

# data[].attributes.subject
There is a weak positive correlation between the imp_a500 variable and the target value

# data[].attributes.body
cor(pm$imp_a500, pm$value)

[1] 0.2779237

# data[].attributes.body
higher percentage of no high school sometimes correlated to higher emissions in 25000m radius

also learned that the mean zcta area is around 183 million squared meters, much smaller than the smallest circle radius (500 m radius --> approx. 785,398 square meters)

# data[].attributes.body
there is a negative correlation between urc and nei variables (the more "urban" a county is, the greater the sum of emissions)

# data[].attributes.body
Tried to log transform the zcta_pop and popdens_zcta to see the correlation between the two columns and some of the columns that I felt might be important to gain an insight. However, I might have done something wrong as the correlation doesn't populate accordingly. Might be the way I did log transform that caused it to messed up but from the graph I didn't see any strong correlation.

# data[].attributes.body
I wanted to look at density of emissions using nei, just how we looked at pri (road length). I think it could be better visualized since it's highly concentrated

# data[].attributes.headline
County Population Density vs value, aod, CMAQ

# data[].attributes.subject
County Population Density vs value, aod, CMAQ

# data[].attributes.body
Seems like population density is not highly correlated with some of the air pollution metrics

# data[].attributes.headline
Weak correlation between lack of high school attainment and popdens

# data[].attributes.subject
Weak correlation between lack of high school attainment and popdens

# data[].attributes.body
This code plots the relationship between the number of monitors a city has and the value of pm10 in a 10,000 meter radius. It seems like there is a slight positive correlation between the number of monitors and pm10 value