Site 1 has a larger species richness than Site 2 because there is a larger total number of different species. Site 2 does have a larger species evenness though because the relative abundance of each species is more equal, while Site 1 has one species dominating the ecosystem with only one of each for other species.
library(ggplot2)
library(vegan)
## Loading required package: permute
## Loading required package: lattice
## This is vegan 2.5-2
library(reshape)
library(plyr)
##
## Attaching package: 'plyr'
## The following objects are masked from 'package:reshape':
##
## rename, round_any
bisonImport <- read.csv("C:\\Users\\gabriela\\Downloads\\bisonWtAge.csv")
bisonImport$age <- as.factor(bisonImport$age) #make age a factor
#individual count in each age class per year
countAge <- ddply(bisonImport, c("year", "age", "sex"), summarise, count=sum(!is.na(weight)))
countAge$age <- as.factor(countAge$age) #make age a factor
#graphing data set for bison age counts by sex
bisonAge <- ddply(countAge, c("age", "sex"), summarise, dataMean=mean(count, na.rm=T), dataSD=sd(count,na.rm=T))
#graphing data for bison weights by sex
bisonWeight <- ddply(bisonImport, c("age", "sex"), summarise, dataMean=mean(weight, na.rm=T), dataSD=sd(weight,na.rm=T))
#load the graphing data for the x and y axis
graphBar <- ggplot(data=bisonAge, aes(x=age, y=dataMean, fill=sex))
#set error bar limits using SD or SE around the mean
limits <- aes(ymax=dataMean + dataSD, ymin=dataMean - dataSD)
dodge <- position_dodge(width=0.9)
graphBar + theme_classic() + geom_bar(stat="identity", position=dodge, colour="black") + geom_errorbar(limits, width=0.2, position=dodge) + scale_fill_brewer(palette="Paired")
## Warning: Removed 2 rows containing missing values (geom_errorbar).
Average Number of Individuals Per Age
In this graph I was analyzing the average number of individuals per age. From this graph I learned that the number of male individuals decrease with an increasing age. The number of male individuals is at 0 at 10 years old. The number of females also decreases with an increasing age, however the number of female individuals doesn’t get to 0 until after 21 years old. From this I can conclude that female bison populations are larger and they live longer.
library(ggplot2)
library(vegan)
library(plyr)
library(reshape)
#load the graphing data for the x and y axis
graphBar <- ggplot(data=bisonWeight, aes(x=age, y=dataMean, fill=sex))
#set error bar limmits using SD or SE around the mean
limits <- aes(ymax=dataMean + dataSD, ymin=dataMean - dataSD)
dodge <- position_dodge(width=0.9)
graphBar + theme_classic() + geom_bar(stat="identity", position=dodge, colour="black") + geom_errorbar(limits, width=0.2, position=dodge) + scale_fill_brewer(palette="Paired")
## Warning: Removed 2 rows containing missing values (geom_errorbar).
Average weight of individuals per age
In this graph I was analyzing the average weight of individuals per age. From this graph I learned that the weight of male individuals increases until the age of 10 years old, and get much heavier than female bison. The weight of female individuals increases steadily until about 6 years old, then levels off and stays at the same weight until 21 years. From this I can conclude that male weight increases quickly and then they die, while female weight is steady and they live longer.
Bison grazing plays an important role in maintaining the ecosystem by stimulating plants to grow, which triggers biological activity and nutrient exchanges. Grazing creates a heterogeneous plant community which can change fire-return cycles, fire intensity, and spread patterns. So if the amount of bison grazing increases and the fire regimes will increase then bird diversity will also increase. Grazing can cause seed dispersal via transporting seed in coats, feet, or digestive tracts and the grazing compaction may facilitate germination. The increase of seeds in the seed bank, and frequent fires that kill off invasive species give opportunity for new seeds to sprout, attracting different bird species.
Grazing affecs the species composition of a plant community, and can either increase or decrease seed production, dispersal, and germination. When bison graze they usually graze on the most dominant grasses while avoiding most species which allows for the grasses and other species to recover which enhances aboveground biomass, density and plant cover. The grazing from bison also increases photosynthesis rates due to increased light availabilty. So if bison grazing and fire frequency increases then plant diversity will also increase.
Increased fire frequency is the only disturbance that has a significant effect on grasshopper composition. Most grasshopper speceis favor recently burned or grazed grasslands. So an increase in bison grazing and fire frequency will increase grasshopper diversity.
#bird data import
birdImport <- read.csv("C:\\Users\\gabriela\\Downloads\\birdBison.csv")
summary(birdImport)
## plotCode watershed year spCode
## 1982_N01B: 38 N01B : 688 Min. :1981 DICK : 257
## 1983_N01B: 37 N04D : 657 1st Qu.:1986 EMDL : 178
## 1984_N01B: 37 N20B : 624 Median :1993 BHCB : 177
## 1982_N04B: 36 020C : 571 Mean :1994 GRAS : 156
## 1986_N01B: 35 N04B : 545 3rd Qu.:2002 THRA : 148
## 1986_N20B: 34 020B : 490 Max. :2009 BOBW : 143
## (Other) :4590 (Other):1232 (Other):3748
## count totalCount relAbund
## Min. : 1.000 Min. : 15.00 Min. :0.002755
## 1st Qu.: 1.000 1st Qu.: 53.00 1st Qu.:0.015152
## Median : 2.000 Median : 83.00 Median :0.030568
## Mean : 4.315 Mean : 93.23 Mean :0.054088
## 3rd Qu.: 5.000 3rd Qu.:119.00 3rd Qu.:0.067682
## Max. :139.000 Max. :363.00 Max. :0.743316
##
#plant data import
plantImport <- read.csv("C:\\Users\\gabriela\\Downloads\\plantBison.csv")
summary(plantImport)
## plotCode watershed year plot
## 2017_N20B_1_D: 94 N04D :34507 Min. :1983 Min. :1.000
## 2017_N20B_3_C: 87 N20B :33904 1st Qu.:1994 1st Qu.:2.000
## 2017_N04D_1_A: 86 N01B :27473 Median :2001 Median :3.000
## 2017_N04D_5_B: 83 004B :25153 Mean :2001 Mean :2.991
## 2017_N20B_1_C: 83 020B :25100 3rd Qu.:2009 3rd Qu.:4.000
## 2013_N04D_1_A: 82 004A :22412 Max. :2017 Max. :5.000
## (Other) :195724 (Other):27690
## transect spCode cover totalCover
## A:47617 sp2 : 5065 Min. :0.0050 Min. : 0.760
## B:49277 sp18 : 5024 1st Qu.:0.0050 1st Qu.: 3.210
## C:49831 sp46 : 4943 Median :0.0150 Median : 4.050
## D:48894 sp14 : 4911 Mean :0.1043 Mean : 4.157
## E: 620 sp58 : 4865 3rd Qu.:0.0600 3rd Qu.: 4.965
## sp3 : 4740 Max. :5.2250 Max. :10.370
## (Other):166691
## relAbund
## Min. :0.0004822
## 1st Qu.:0.0014265
## Median :0.0042827
## Mean :0.0259123
## 3rd Qu.:0.0140351
## Max. :0.8986175
##
#grasshopper data import
grasshopperImport <- read.csv("C:\\Users\\gabriela\\Downloads\\grasshopperBison.csv")
summary(grasshopperImport)
## plotCode watershed year spCode
## 2002_N01B: 31 001D:357 Min. :1982 sp9 : 122
## 2002_N04D: 27 004B:361 1st Qu.:1999 sp15 : 119
## 2003_N01B: 26 020B:257 Median :2005 sp12 : 113
## 2003_N04D: 26 N01B:290 Mean :2003 sp4 : 101
## 2003_N20B: 24 N04D:302 3rd Qu.:2010 sp21 : 94
## 2014_N20B: 24 N20B:241 Max. :2014 sp10 : 91
## (Other) :1650 (Other):1168
## count totalCount relAbund
## Min. : 1.00 Min. : 19.0 Min. :0.0002421
## 1st Qu.: 2.00 1st Qu.: 156.0 1st Qu.:0.0064103
## Median : 5.00 Median : 296.0 Median :0.0203143
## Mean : 28.79 Mean : 448.6 Mean :0.0680310
## 3rd Qu.: 19.00 3rd Qu.: 560.0 3rd Qu.:0.0676452
## Max. :1967.00 Max. :4131.0 Max. :0.8618785
##
#import meta data for watershed code
habitat <- read.csv("C:\\Users\\gabriela\\Downloads\\bisonPlotMeta.csv")
whatsMyData <- "BIRD"
myDiversityData <- birdImport #some biotic data from above
#create dataframe with library(reshape)
div <- cast(myDiversityData, plotCode ~ spCode, value="relAbund")
div[is.na(div)] <- 0 #make all NA values zero
rownames(div) <- div[,1] #make first column row names
div <- div[,-1] #drop first column
#Diversity Indicies
spdiv <- specnumber(div) #richness
Hdiv <- diversity(div, index="shannon") #shannon diversity
Ddiv <- diversity(div, index="invsimpson") #simpson 1/d diversity
#make final data frame
konzaDiv <- data.frame(spdiv, Hdiv, Ddiv)
konzaDiv$plotCode <- rownames(konzaDiv) #make a column of row names
#need to split the data to get watershed code and year
temp <- strsplit(konzaDiv$plotCode, "_")
mat <-matrix(unlist(temp), ncol=2, byrow=TRUE)
splitData <- as.data.frame(mat)
colnames(splitData) <- c("year", "watershed")
#add back to main dataset
konzaDiv$year <- splitData$year
konzaDiv$watershed <- splitData$watershed
#merge dataset
konza <- merge(konzaDiv, habitat, by ="watershed")
summary(konza)
## watershed spdiv Hdiv Ddiv
## 001D :29 Min. : 7.00 Min. :1.205 Min. : 1.787
## 004A :29 1st Qu.:14.00 1st Qu.:2.266 1st Qu.: 6.969
## 004B :29 Median :18.00 Median :2.443 Median : 8.935
## 020B :29 Mean :18.49 Mean :2.447 Mean : 9.103
## 020C :29 3rd Qu.:22.00 3rd Qu.:2.663 3rd Qu.:10.980
## N01B :29 Max. :38.00 Max. :3.149 Max. :19.379
## (Other):86
## plotCode year habitat burnCycle
## Length:260 1982 : 9 galleryForest: 0 burn01Yr: 58
## Class :character 1983 : 9 prairie :260 burn04Yr:116
## Mode :character 1984 : 9 riparianEdge : 0 burn20Yr: 86
## 1985 : 9
## 1986 : 9
## 1987 : 9
## (Other):206
## bisonGrazed size_km
## bison :115 Min. :0.3430
## noBison:145 1st Qu.:0.5940
## Median :0.9020
## Mean :0.9041
## 3rd Qu.:0.9610
## Max. :1.6300
##
## info
## Ungrazed_and_scheduled_prescribed_burned_annually_in_the_spring :29
## Ungrazed_and_scheduled_prescribed_burned_every_20_years_in_the_spring :58
## Ungrazed_and_scheduled_prescribed_burned_every_4_years_in_the_spring :58
## Year_long_grazing_by_bison_and_scheduled_prescribed_burned_annually_in_the_spring :29
## Year_long_grazing_by_bison_and_scheduled_prescribed_burned_every_20_years_in_the_spring:28
## Year_long_grazing_by_bison_and_scheduled_prescribed_burned_every_4_years_in_the_spring :58
##
boxplot(spdiv ~ bisonGrazed + burnCycle, data=konza, main="Richness")
Bird Diversity Analysis
boxplot(Hdiv ~ bisonGrazed + burnCycle, data=konza, main="Shannon")
Bird Diversity Analysis
boxplot(Ddiv ~ bisonGrazed + burnCycle, data=konza, main= "simpson")
Bird Diversity Analysis
whatsMyData
## [1] "BIRD"
BirdImport.aov <- aov(spdiv ~ bisonGrazed * burnCycle, data=konza, main="Richness")
## Warning: In lm.fit(x, y, offset = offset, singular.ok = singular.ok, ...) :
## extra argument 'main' will be disregarded
plot(BirdImport.aov)
Bird Diversity Analysis
Bird Diversity Analysis
Bird Diversity Analysis
Bird Diversity Analysis
summary(BirdImport.aov)
## Df Sum Sq Mean Sq F value Pr(>F)
## bisonGrazed 1 2345 2345.2 87.188 < 2e-16 ***
## burnCycle 2 438 219.2 8.148 0.000372 ***
## bisonGrazed:burnCycle 2 435 217.6 8.089 0.000393 ***
## Residuals 254 6832 26.9
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
#data automation
whatsMyData <- "Plant"
myDiversityData <- plantImport #some biotic data from above
#create dataframe with library(reshape)
div <- cast(myDiversityData, plotCode ~ spCode, value="relAbund")
div[is.na(div)] <- 0 #make all NA values zero
rownames(div) <- div[,1] #make first column row names
div <- div[,-1] #drop first column
#Diversity Indicies
spdiv <- specnumber(div) #richness
Hdiv <- diversity(div, index="shannon") #shannon diversity
Ddiv <- diversity(div, index="invsimpson") #simpson 1/d diversity
#make final data frame
konzaDiv <- data.frame(spdiv, Hdiv, Ddiv)
konzaDiv$plotCode <- rownames(konzaDiv) #make a column of row names
#need to split the data to get watershed code and year
temp <- strsplit(konzaDiv$plotCode, "_")
mat <-matrix(unlist(temp), ncol=4, byrow=TRUE)
splitData <- as.data.frame(mat)
colnames(splitData) <- c("year", "watershed", "transect", "plot")
#add back to main dataset
konzaDiv$year <- splitData$year
konzaDiv$watershed <- splitData$watershed
#merge dataset
konza <- merge(konzaDiv, habitat, by ="watershed")
summary(konza)
## watershed spdiv Hdiv Ddiv
## N20B :705 Min. : 9.00 Min. :0.5424 Min. : 1.236
## 001D :700 1st Qu.:30.00 1st Qu.:1.9726 1st Qu.: 4.242
## 004B :700 Median :36.00 Median :2.3274 Median : 6.148
## 020B :700 Mean :38.59 Mean :2.3007 Mean : 6.709
## N04D :700 3rd Qu.:46.00 3rd Qu.:2.6385 3rd Qu.: 8.591
## N01B :680 Max. :94.00 Max. :3.4352 Max. :18.408
## (Other):900
## plotCode year habitat burnCycle
## Length:5085 1997 : 180 galleryForest: 0 burn01Yr:1460
## Class :character 1998 : 180 prairie :5085 burn04Yr:2060
## Mode :character 1999 : 180 riparianEdge : 0 burn20Yr:1565
## 2000 : 180
## 1993 : 160
## 1994 : 160
## (Other):4045
## bisonGrazed size_km
## bison :2085 Min. :0.3430
## noBison:3000 1st Qu.:0.5450
## Median :0.9140
## Mean :0.9569
## 3rd Qu.:1.4900
## Max. :1.6300
##
## info
## Ungrazed_and_scheduled_prescribed_burned_annually_in_the_spring : 780
## Ungrazed_and_scheduled_prescribed_burned_every_20_years_in_the_spring : 860
## Ungrazed_and_scheduled_prescribed_burned_every_4_years_in_the_spring :1360
## Year_long_grazing_by_bison_and_scheduled_prescribed_burned_annually_in_the_spring : 680
## Year_long_grazing_by_bison_and_scheduled_prescribed_burned_every_20_years_in_the_spring: 705
## Year_long_grazing_by_bison_and_scheduled_prescribed_burned_every_4_years_in_the_spring : 700
##
boxplot(spdiv ~ bisonGrazed + burnCycle, data=konza, main="Richness")
Plant Diversity Analysis
boxplot(Hdiv ~ bisonGrazed + burnCycle, data=konza, main="Shannon")
Plant Diversity Analysis
boxplot(Ddiv ~ bisonGrazed + burnCycle, data=konza, main= "simpson")
Plant Diversity Analysis
PlantImport.aov <- aov(spdiv ~ bisonGrazed * burnCycle, data=konza, main="Richness")
## Warning: In lm.fit(x, y, offset = offset, singular.ok = singular.ok, ...) :
## extra argument 'main' will be disregarded
plot(PlantImport.aov)
Plant Diversity Analysis
Plant Diversity Analysis
Plant Diversity Analysis
Plant Diversity Analysis
summary(PlantImport.aov)
## Df Sum Sq Mean Sq F value Pr(>F)
## bisonGrazed 1 193306 193306 2096.268 < 2e-16 ***
## burnCycle 2 70951 35475 384.705 < 2e-16 ***
## bisonGrazed:burnCycle 2 1664 832 9.021 0.000123 ***
## Residuals 5079 468356 92
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
grasshopperImport <- read.csv("C:\\Users\\gabriela\\Downloads\\grasshopperBison.csv")
whatsMyData <- "Grasshopper"
myDiversityData <- grasshopperImport #some biotic data from above
#create dataframe with library(reshape)
div <- cast(myDiversityData, plotCode ~ spCode, value="relAbund")
div[is.na(div)] <- 0 #make all NA values zero
rownames(div) <- div[,1] #make first column row names
div <- div[,-1] #drop first column
#Diversity Indicies
spdiv <- specnumber(div) #richness
Hdiv <- diversity(div, index="shannon") #shannon diversity
Ddiv <- diversity(div, index="invsimpson") #simpson 1/d diversity
#make final data frame
konzaDiv <- data.frame(spdiv, Hdiv, Ddiv)
konzaDiv$plotCode <- rownames(konzaDiv) #make a column of row names
#need to split the data to get watershed code and year
temp <- strsplit(konzaDiv$plotCode, "_")
mat <-matrix(unlist(temp), ncol=2, byrow=TRUE)
splitData <- as.data.frame(mat)
colnames(splitData) <- c("year", "watershed")
#add back to main dataset
konzaDiv$year <- splitData$year
konzaDiv$watershed <- splitData$watershed
#merge dataset
konza <- merge(konzaDiv, habitat, by ="watershed")
summary(konza)
## watershed spdiv Hdiv Ddiv
## 001D:29 Min. : 5.0 Min. :0.5966 Min. : 1.333
## 004B:29 1st Qu.:11.0 1st Qu.:1.4891 1st Qu.: 2.839
## 020B:19 Median :14.0 Median :1.7376 Median : 4.007
## N01B:16 Mean :14.7 Mean :1.7620 Mean : 4.543
## N04D:17 3rd Qu.:17.5 3rd Qu.:2.0968 3rd Qu.: 5.988
## N20B:13 Max. :31.0 Max. :2.6327 Max. :11.449
##
## plotCode year habitat burnCycle
## Length:123 2002 : 6 galleryForest: 0 burn01Yr:45
## Class :character 2003 : 6 prairie :123 burn04Yr:46
## Mode :character 2004 : 6 riparianEdge : 0 burn20Yr:32
## 2005 : 6
## 2006 : 6
## 2007 : 6
## (Other):87
## bisonGrazed size_km
## bison :46 Min. :0.545
## noBison:77 1st Qu.:0.902
## Median :0.914
## Mean :1.015
## 3rd Qu.:0.961
## Max. :1.630
##
## info
## Ungrazed_and_scheduled_prescribed_burned_annually_in_the_spring :29
## Ungrazed_and_scheduled_prescribed_burned_every_20_years_in_the_spring :19
## Ungrazed_and_scheduled_prescribed_burned_every_4_years_in_the_spring :29
## Year_long_grazing_by_bison_and_scheduled_prescribed_burned_annually_in_the_spring :16
## Year_long_grazing_by_bison_and_scheduled_prescribed_burned_every_20_years_in_the_spring:13
## Year_long_grazing_by_bison_and_scheduled_prescribed_burned_every_4_years_in_the_spring :17
##
boxplot(spdiv ~ bisonGrazed + burnCycle, data=konza, main="Richness")
Grasshopper Diversity Analysis
boxplot(Hdiv ~ bisonGrazed + burnCycle, data=konza, main="Shannon")
Grasshopper Diversity Analysis
boxplot(Ddiv ~ bisonGrazed + burnCycle, data=konza, main= "simpson")
Grasshopper Diversity Analysis
whatsMyData
## [1] "Grasshopper"
grasshopperImport.aov <- aov(spdiv ~ bisonGrazed * burnCycle, data=konza, main="Richness")
## Warning: In lm.fit(x, y, offset = offset, singular.ok = singular.ok, ...) :
## extra argument 'main' will be disregarded
plot(grasshopperImport.aov)
Grasshopper Diversity Analysis
Grasshopper Diversity Analysis
Grasshopper Diversity Analysis
Grasshopper Diversity Analysis
summary(grasshopperImport.aov)
## Df Sum Sq Mean Sq F value Pr(>F)
## bisonGrazed 1 854.2 854.2 52.430 5.09e-11 ***
## burnCycle 2 20.5 10.3 0.630 0.535
## bisonGrazed:burnCycle 2 3.0 1.5 0.092 0.912
## Residuals 117 1906.2 16.3
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
Diversity is a very important factor when it comes to Ecological Restoration because the sucessfulness of an ecosystem is dependent on its diversity. For example, having a more diverse population of plants, will attract a wide range of bird species that use the nectar from all of these plants. If an ecosystem were to have little diversity then it wouldn’t be able to be the home for a wide range of organisms to allow the ecosystem to provide its basic ecosystem services. Diversity indices can measure restoration success by providing information about the population before and after the restoration project. You can measure species richness and evenness to get an idea of which species were restored and populations are increasing again, and you can also get an idea as to which species are dominating and are potentially invasive. I think species evenness is the most important index to measure restoration progress because you can count the amount of a particular invasive species to see if the restoration work being done is decreasing that amount. The restoring and conservation of an endangered native species can also be measure using species evenness to see if that population is increasing. There is a significant relationship between bison fire, and plant, bird, and grasshopper diversity. All of the p-values were less than 0.05, which indicates that there is statisitical evidence that there is a positive relationship between grazing bison, fire and species diversity of that ecosystem. Large hoofed animals can be used as a tool for restoration even though they are often ignored. Creative ways that we can incorporate bison into habitat management plans are simply introducing bison, or other hoofed animals into praires. Bison graze grasses and create open areas by trampling the ground, and also promote seed germination by spreading seeds. The addition of bison can replace many unsustainable practices that we currently have to use.