x <- read.csv("C:/Users/chahi/OneDrive/Desktop/ant109 r docs/assignment3/species richness csv files/bird layer.csv")
y <- read.csv("C:/Users/chahi/OneDrive/Desktop/ant109 r docs/assignment3/species richness csv files/mammal layer.csv")
z <- read.csv("C:/Users/chahi/OneDrive/Desktop/ant109 r docs/assignment3/species richness csv files/reptile layer.csv")
Each dataset contains 63890 hexagons.
nrow(x)
## [1] 63890
nrow(y)
## [1] 63890
nrow(z)
## [1] 63890
dat2 <- merge(x, y)
dat2 <- merge(dat2, z)
par(mfrow=c(1,3))
hist(dat2$NtvBird, xlab="Count", ylab= "Frequency", main = "Native Birds", col="#6ba448")
hist(dat2$NtvMamm, xlab="Count", ylab="Frequency", main="Native Mammals", col="#4f91d1")
hist(dat2$NtvRept, xlab="Count", ylab="Frequency", main="Native Repitles", col="#4aac8b")
These graphs show the distributions of native birds, mammals, and reptiles in California.
par(mfrow=c(1,3))
plot(dat2$NtvMamm, dat2$NtvBird, col="#6ba448", xlab="Mammals", ylab="Birds", main="Mammals vs Birds")
plot(dat2$NtvMamm, dat2$NtvRept, col="#4f91d1", xlab="Mammals", ylab="Reptiles", main="Mammals vs Reptiles")
plot(dat2$NtvBird, dat2$NtvRept, col="#4aac8b", xlab="Birds", ylab="Reptiles", main="Birds vs Reptiles")
The relationship between counts of native mammals and native birds, native mammals and native reptiles, and native birds and native reptiles within California are presented. No clear correlation is revealed.
Based on this graph, bird frequency is higher in the Central Valley, the Bay Area, as well as parts of Southern California, including the LA coast and a small region right by the border with Mexico. Bird populations seem significantly less frequent in the Mojave Desert and along the Sierra Nevada.