aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKen Kellner <ken.kellner@gmail.com>2016-10-12 18:44:26 (GMT)
committerKen Kellner <ken.kellner@gmail.com>2016-10-12 18:44:26 (GMT)
commitd726353e207e31b6bf5e630e5d1e44ed010d399b (patch)
treef455d4c76a308e2e81100575c5b663b90b94fcfe
parent51f8450fc856f5200a2023bb3dea6ca30d063bd5 (diff)
Prep files to be made public. Add example data files.v1.0
-rw-r--r--.gitignore3
-rw-r--r--README.md2
-rw-r--r--analysis_abun_hl.R19
-rw-r--r--analysis_abun_mu.R19
-rw-r--r--data/bird_codes.csv66
-rw-r--r--data/example_count_data.csv11
-rw-r--r--data/example_observer_data.csv11
-rw-r--r--data/example_point_data.csv11
-rw-r--r--data/example_survey_data.csv11
-rw-r--r--figures/figure_birddens.R11
-rw-r--r--figures/figure_multidens.R12
-rw-r--r--figures/figure_rawdata.R32
-rw-r--r--figures/figure_resp_summary.R9
-rw-r--r--figures/figure_richness.R9
-rw-r--r--function_gen_treat_arrays.R9
-rw-r--r--presentations/figures_fscc2016.R4
-rw-r--r--presentations/talk_tws2016.tex10
17 files changed, 216 insertions, 33 deletions
diff --git a/.gitignore b/.gitignore
index b18977a..9d865aa 100644
--- a/.gitignore
+++ b/.gitignore
@@ -2,14 +2,13 @@
.Rhistory
.RData
*.Rproj
-data*
+hee_*
output*
*pdf
*bib
*.log
*tiff
*.html
-*.csv
*.toc
*.gz
*.out
diff --git a/README.md b/README.md
index 2a61294..8ee054b 100644
--- a/README.md
+++ b/README.md
@@ -5,7 +5,7 @@ An analysis of the response of breeding birds to forest management at the [Hardw
The results are published in the following article:
-[*Kellner, Kenneth F.; Ruhl, Patrick J.; Dunning, John B.; Riegel, Jeffery K.; Swihart, Robert K. 2016. Multi-scale responses of breeding birds to experimental forest management in Indiana, USA. Forest Ecology and Management*]()
+[*Kellner, Kenneth F.; Ruhl, Patrick J.; Dunning, John B.; Riegel, Jeffery K.; Swihart, Robert K. 2016. Multi-scale responses of breeding birds to experimental forest management in Indiana, USA. Forest Ecology and Management 382: 64-75.*](http://dx.doi.org/10.1016/j.foreco.2016.10.008)
Metadata
====================
diff --git a/analysis_abun_hl.R b/analysis_abun_hl.R
index 42d79fe..1d38ffb 100644
--- a/analysis_abun_hl.R
+++ b/analysis_abun_hl.R
@@ -1,16 +1,17 @@
-################################################
-## Community Abundance Model of HEE Bird Data ##
-################################################
+###################################
+## HEE Bird Data ##
+## Harvest-Scale Abundance Model ##
+###################################
#Required functions
source('function_birdobs_parse.R')
source('function_birdsurvey_parse.R')
#Parse raw data
-cov.data <- birdsurvey.parse('data/point_data.csv','data/survey_data.csv',
- 'data/observer_data.csv')
+cov.data <- birdsurvey.parse('data/hee_point_data.csv','data/hee_survey_data.csv',
+ 'data/hee_observer_data.csv')
-obs.data <- birdobs.parse('data/count_data.csv',survey.info=cov.data$survey.info,
+obs.data <- birdobs.parse('data/hee_count_data.csv',survey.info=cov.data$survey.info,
output='Nmix',territoryonly=T,min.count=50,
exclude.species=c('UNWA','EACH','EGSQ','UNFL','UNBI','RUGR','BPLW','WPWI'),
distupperlims=75,adjust.patch=TRUE)
@@ -40,6 +41,7 @@ for (i in 1:length(per)){
per <- cov.data$survey.info$year
+#Detection covariates
observer <- cov.data$survey.info$obscode
nobservers <- max(observer)
@@ -58,6 +60,7 @@ hr.raw <- cov.data$survey.info$time
hr <- as.numeric(scale(hr.raw))
hr[which(is.na(hr))] <- 0
+#Indexes for management unit and survey
unit <- cov.data$survey.info$unitcode
nunits <- max(unit)
@@ -81,6 +84,7 @@ for (i in 1:length(sample.area)){
if(cov.data$survey.info$point[i]%in%ha1&cov.data$survey.info$year[i]>3){sample.area[i] <- 0.640} #60 m radius
}
+#Arguments for JAGS
model.file <- 'models/model_abun_hl.R'
jags.data <- c('y', 'sample.area',
@@ -120,17 +124,20 @@ inits <- function(){
library(jagsUI)
library(RPushbullet)
+#Run model
start.time <- Sys.time()
out.hl <- jags(data=jags.data,inits=inits,parameters.to.save=params,model.file=model.file,
n.chains=3,n.iter=50000,n.burnin=45000,n.thin=50,parallel=T,codaOnly=c('N'))
obs.data.hl <- obs.data
+#Extract summary arrays to use in figures
source('function_gen_treat_arrays.R')
hl.array <- gen.treat.array(out.hl,cov.data,obs.data.hl,species,scale='hl')
Ntreat.harvest <- hl.array$Ntreat
Rtreat.harvest <- hl.array$Rtreat
+#Save output
save(out.hl,cov.data,obs.data.hl,species,Ntreat.harvest,Rtreat.harvest,file='output/hl_bird_abun.Rdata',compress=TRUE)
end.time <- Sys.time()
diff --git a/analysis_abun_mu.R b/analysis_abun_mu.R
index 390214c..3cb82df 100644
--- a/analysis_abun_mu.R
+++ b/analysis_abun_mu.R
@@ -1,16 +1,17 @@
-################################################
-## Community Abundance Model of HEE Bird Data ##
-################################################
+###########################################
+## HEE Bird Data ##
+## Management-Unit Scale Abundance Model ##
+###########################################
#Required functions
source('function_birdobs_parse.R')
source('function_birdsurvey_parse.R')
#Parse raw data
-cov.data <- birdsurvey.parse('data/point_data.csv','data/survey_data.csv',
- 'data/observer_data.csv')
+cov.data <- birdsurvey.parse('data/hee_point_data.csv','data/hee_survey_data.csv',
+ 'data/hee_observer_data.csv')
-obs.data <- birdobs.parse('data/count_data.csv',survey.info=cov.data$survey.info,
+obs.data <- birdobs.parse('data/hee_count_data.csv',survey.info=cov.data$survey.info,
output='Nmix',territoryonly=T,min.count=50,
exclude.species=c('UNWA','EACH','EGSQ','UNFL','UNBI','RUGR','BPLW','WPWI'),
distupperlims=75)
@@ -33,6 +34,7 @@ for (i in 1:length(per)){
per <- cov.data$survey.info$year
+#Detection covariates
observer <- cov.data$survey.info$obscode
nobservers <- max(observer)
@@ -51,6 +53,7 @@ hr.raw <- cov.data$survey.info$time
hr <- as.numeric(scale(hr.raw))
hr[which(is.na(hr))] <- 0
+#Indexes for management unit and survey
unit <- cov.data$survey.info$unitcode
nunits <- max(unit)
@@ -62,6 +65,7 @@ y <- obs.data$y
trans <- obs.data$trans
nsites <- obs.data$nsites
+#Arguments for JAGS
model.file <- 'models/model_abun_mu.R'
jags.data <- c('y',
@@ -93,17 +97,20 @@ inits <- function(){
library(jagsUI)
library(RPushbullet)
+#Run model
start.time <- Sys.time()
out.mu <- jags(data=jags.data,inits=inits,parameters.to.save=params,model.file=model.file,
n.chains=3,n.iter=50000,n.burnin=45000,n.thin=50,parallel=T,codaOnly=c('N'))
obs.data.mu <- obs.data
+#Extract summary arrays to use in figures
source('function_gen_treat_arrays.R')
mu.array <- gen.treat.array(out.mu,cov.data,obs.data.mu,species,scale='mu')
Ntreat <- mu.array$Ntreat
Rtreat <- mu.array$Rtreat
+#Save output
save(out.mu,cov.data,obs.data.mu,species,Ntreat,Rtreat,file='output/mu_bird_abun.Rdata',compress=T)
end.time <- Sys.time()
diff --git a/data/bird_codes.csv b/data/bird_codes.csv
new file mode 100644
index 0000000..fbbd366
--- /dev/null
+++ b/data/bird_codes.csv
@@ -0,0 +1,66 @@
+Alpha Code,Common Name,Scientific Name
+ACFL,Acadian Flycatcher,Empidonax virescens
+AMGO,American Goldfinch,Spinus tristis
+AMRE,American Redstart,Setophaga ruticilla
+AMRO,American Robin,Turdus migratorius
+BAOR,Baltimore Oriole,Icterus galbula
+BAWW,Black-and-white Warbler,Mniotilta varia
+BGGN,Blue-gray Gnatcatcher,Polioptila caerulea
+BHCO,Brown-headed Cowbird,Molothrus ater
+BRCR,Brown Creeper,Certhia americana
+BRTH,Brown Thrasher,Toxostoma rufum
+BTNW,Black-throated Green Warbler,Setophaga virens
+BWWA,Blue-winged Warbler,Vermivora cyanoptera
+CACH,Carolina Chickadee,Poecile carolinensis
+CARW,Carolina Wren,Thryothorus ludovicianus
+CERW,Cerulean Warbler,Setophaga cerulea
+CHSP,Chipping Sparrow,Spizella passerina
+COYE,Common Yellowthroat,Geothlypis trichas
+CSWA,Chestnut-sided Warbler,Setophaga pensylvanica
+DOWO,Downy Woodpecker,Picoides pubescens
+EABL,Eastern Bluebird,Sialia sialis
+EAKI,Eastern Kingbird,Tyrannus tyrannus
+EAPH,Eastern Phoebe,Sayornis phoebe
+EATO,Eastern Towhee,Pipilo erythrophthalmus
+EAWP,Eastern Wood-pewee,Contopus virens
+FISP,Field Sparrow,Spizella pusilla
+GCFL,Great Crested Flycatcher,Myiarchus crinitus
+GRCA,Gray Catbird,Dumetella carolinensis
+HAWO,Hairy Woodpecker,Leuconotopicus villosus
+HOWA,Hooded Warbler,Setophaga citrina
+HOWR,House Wren,Troglodytes aedon
+INBU,Indigo Bunting,Passerina cyanea
+KEWA,Kentucky Warbler,Geothlypis formosa
+LOWA,Louisiana Waterthrush,Parkesia motacilla
+MAWA,Magnolia Warbler,Setophaga magnolia
+MODO,Mourning Dove,Zenaida macroura
+NAWA,Nashville Warbler,Leiothlypis ruficapilla
+NOCA,Northern Cardinal,Cardinalis cardinalis
+NOPA,Northern Parula,Setophaga americana
+NOWA,Northern Waterthrush,Parkesia noveboracensis
+OVEN,Ovenbird,Seiurus aurocapilla
+PIWA,Pine Warbler,Setophaga pinus
+PIWO,Pileated Woodpecker,Hylatomus pileatus
+PRAW,Prairie Warbler,Setophaga discolor
+RBGR,Rose-breasted Grosbeak,Pheucticus ludovicianus
+RBWO,Red-bellied Woodpecker,Melanerpes carolinus
+REVI,Red-eyed Vireo,Vireo olivaceus
+RHWO,Red-headed Woodpecker,Melanerpes erythrocephalus
+RTHU,Ruby-throated Hummingbird,Archilochus colubris
+RWBL,Red-winged Blackbird,Agelaius phoeniceus
+SCTA,Scarlet Tanager,Piranga olivacea
+SUTA,Summer Tanager,Piranga rubra
+TRES,Tree Swallow,Tachycineta bicolor
+TUTI,Tufted Titmouse,Baeolophus bicolor
+WAVI,Warbling Vireo,Vireo gilvus
+WBNU,White-breasted Nuthatch,Sitta carolinensis
+WEVI,White-eyed Vireo,Vireo griseus
+WEWA,Worm-eating Warbler,Helmitheros vermivorum
+WITU,Wild Turkey,Meleagris gallopavo
+WOTH,Wood Thrush,Hylocichla mustelina
+YBCH,Yellow-breasted Chat,Icteria virens
+YBCU,Yellow-billed Cuckoo,Coccyzus americanus
+YEWA,Yellow Warbler,Setophaga petechia
+YSFL,Northern Flicker,Colaptes auratus
+YTVI,Yellow-throated Vireo,Vireo flavifrons
+YTWA,Yellow-throated Warbler,Setophaga dominica
diff --git a/data/example_count_data.csv b/data/example_count_data.csv
new file mode 100644
index 0000000..6f51fe5
--- /dev/null
+++ b/data/example_count_data.csv
@@ -0,0 +1,11 @@
+"BirdPointID","Interval","Species","IDMethod","Sex","Distance","Territory"
+47,3,"WBNU","S","M","50",""
+613,8,"WOTH","S","M","110",""
+905,1,"REVI","S","M","40",""
+2367,9,"UNWO","D","U","60",""
+2686,1,"RSTO","S","M","40",""
+2779,6,"CACH","S","M","40",""
+4228,1,"BHCO","C","M","30","T"
+4052,9,"EAWP","S","M","70","T"
+4098,7,"REVI","S","M","30","T"
+4187,2,"TUTI","S","M","90","T"
diff --git a/data/example_observer_data.csv b/data/example_observer_data.csv
new file mode 100644
index 0000000..5e1e0ea
--- /dev/null
+++ b/data/example_observer_data.csv
@@ -0,0 +1,11 @@
+"BirdPointID","Observer"
+507,"TS"
+894,"KN15"
+1300,"JR2"
+1736,"LW"
+1756,"GS"
+2213,"BC"
+2328,"RL"
+2665,"JJ"
+3342,"SF"
+3924,"SF"
diff --git a/data/example_point_data.csv b/data/example_point_data.csv
new file mode 100644
index 0000000..0cec7a7
--- /dev/null
+++ b/data/example_point_data.csv
@@ -0,0 +1,11 @@
+"PointNumber","SampleType","Aspect","Slope","X","Y","DetailType","DistanceToHarvest.m."
+1008,"Breeding",258,35,558612.7504,4331427.925,"group-edge",67
+1108,"Breeding",52,30,558606.1009,4331866.053,"group-edge",31
+1201,"Breeding",66,53,555301.5312,4330214.781,"even-land",138
+1301,"Breeding",30,50,547786.7222,4355212.584,"cont-land",807
+1507,"Breeding",130,35,548836.7222,4356262.584,"group-edge",81
+1711,"Breeding",230,22,547486.7222,4352662.584,"shelter-edge",9
+1718,"Breeding",172,20,NA,NA,"bc-land",7484
+1917,"Breeding",NA,NA,554536.7221,4339612.584,"cont-land",8555
+1918,"Breeding",332,45,561605.1444,4332306.586,"clearcut-edge",46
+2632,"Breeding",192,40,561655.6041,4332425.831,"clearcut",0
diff --git a/data/example_survey_data.csv b/data/example_survey_data.csv
new file mode 100644
index 0000000..2b264a8
--- /dev/null
+++ b/data/example_survey_data.csv
@@ -0,0 +1,11 @@
+"BirdPointID","SampleType","PointNumber","Date","AirTemp","Wind","Sky.Cover","Start.Time","Stop.Time"
+242,"Breeding",1104,"27-May-11",50,2,3,"7:03 AM","7:13 AM"
+564,"Breeding",1131,"04-Jun-07",71,1,0,"7:02 AM","7:12 AM"
+583,"Breeding",1202,"04-Jun-07",65,0,0,"7:18 AM","7:28 AM"
+1209,"Breeding",1404,"29-May-14",68,1,2,"7:11 AM","7:21 AM"
+1449,"Breeding",1424,"27-May-10",60,0,1,"6:35 AM","6:45 AM"
+1882,"Breeding",1614,"02-Jun-08",65,0,1,"8:17 AM","8:28 AM"
+2213,"Breeding",1714,"06-Jun-07",60,1,0,"7:37 AM","7:47 AM"
+2583,"Breeding",1817,"02-Jun-08",70,0,0,"9:20 AM","9:30 AM"
+2935,"Breeding",1915,"22-May-08",60,0,0,"8:00 AM","8:10 AM"
+3403,"Breeding",1019,"26-May-06",55,2,1,"6:40 AM","6:50 AM"
diff --git a/figures/figure_birddens.R b/figures/figure_birddens.R
index 42f78eb..ec2c7f6 100644
--- a/figures/figure_birddens.R
+++ b/figures/figure_birddens.R
@@ -1,4 +1,13 @@
-#Function to plot abundance trends for individual bird species over time
+###############################################################################
+## Function to plot changes in density treatment x year for a single species ##
+###############################################################################
+
+# Arguments:
+# sp: alpha code of species
+# scale: 'mu' for management-unit level, 'hl' for harvest level
+# cred: if TRUE, plot 95% credible intervals
+# se: if TRUE, plot standard error bars
+
bird.figure <- function(sp,scale,
cred=FALSE,se=FALSE,
legendpos='topleft',defaultpar=TRUE,legcex=1,
diff --git a/figures/figure_multidens.R b/figures/figure_multidens.R
index 340b90d..bf5b75b 100644
--- a/figures/figure_multidens.R
+++ b/figures/figure_multidens.R
@@ -1,3 +1,13 @@
+#####################################################
+## Function to create multi-species density figure ##
+#####################################################
+
+# Arguments:
+# sp.include: vector of alpha codes for bird species to include
+# sp.name: optional vector of full species names for titles
+# nrow & ncol: specify dimensions of figure matrix
+# maxy: Maximum y (density) value for each subfigure
+# yticks: Values to plot ticks on y-axis
multidens.figure <- function(sp.include,sp.name=NULL,scale,
nrow,ncol,maxy,yticks,
@@ -99,6 +109,4 @@ multidens.figure <- function(sp.include,sp.name=NULL,scale,
legend(x=legendy,y=legendx,legend.labs,cex=0.8,
lwd=lwd,col=cols,bg="white",lty=ltys,ncol=legendcol)
-
-
} \ No newline at end of file
diff --git a/figures/figure_rawdata.R b/figures/figure_rawdata.R
index 0cd9008..18109d7 100644
--- a/figures/figure_rawdata.R
+++ b/figures/figure_rawdata.R
@@ -1,10 +1,30 @@
-#Generates figures based on raw bird count data (observations/survey)
+###############################################################################
+## Function to plot changes in density treatment x year for a single species ##
+## Based on RAW DATA (no adjustment for detection) ##
+###############################################################################
+#Required functions
+source('function_birdobs_parse.R')
+source('function_birdsurvey_parse.R')
+
+#Parse raw data
+cov.data <- birdsurvey.parse('data/hee_point_data.csv','data/hee_survey_data.csv',
+ 'data/hee_observer_data.csv')
+
+obs.data <- birdobs.parse('data/hee_count_data.csv',survey.info=cov.data$survey.info,
+ output='Nmix',territoryonly=T,min.count=50,
+ exclude.species=c('UNWA','EACH','EGSQ','UNFL','UNBI','RUGR','BPLW','WPWI'),
+ distupperlims=75)
+
+################################################
+
+#Get list of species
allspecies <- unique(obs.data$bird.obs$species)
+#Get number of years
nyears <- max(cov.data$survey.info$year)
-
+#Generate treatment and year categorical variables
yearcode <- contcode <- evencode <- unevencode <- rep(NA,dim(obs.data$bird.obs)[1])
for (i in 1:dim(obs.data$bird.obs)[1]){
yearcode[i] <- cov.data$survey.info$year[obs.data$bird.obs$surveycode[i]]
@@ -13,12 +33,14 @@ for (i in 1:dim(obs.data$bird.obs)[1]){
contcode[i] <- cov.data$survey.info$control[obs.data$bird.obs$surveycode[i]]
}
+#Combine data and categorical variables
temp <- obs.data$bird.obs
temp$yearcode <- yearcode
temp$evencode <- evencode
temp$unevencode <- unevencode
temp$contcode <- contcode
+#Get number of surveys per treatment x year
cont.count <- c(table(cov.data$survey.info$year[cov.data$survey.info$control==1])[1:7],0,
table(cov.data$survey.info$year[cov.data$survey.info$control==1])[8:9])
even.count <- c(table(cov.data$survey.info$year[cov.data$survey.info$even==1])[1:7],0,
@@ -26,8 +48,10 @@ even.count <- c(table(cov.data$survey.info$year[cov.data$survey.info$even==1])[1
uneven.count <- c(table(cov.data$survey.info$year[cov.data$survey.info$uneven==1])[1:7],0,
table(cov.data$survey.info$year[cov.data$survey.info$uneven==1])[8:9])
+#Begin function
raw.bird.figure <- function(species=NULL,all=FALSE){
+ #Sequentially plot for all species if all=TRUE
if(all){
par(ask=TRUE)
@@ -37,6 +61,7 @@ raw.bird.figure <- function(species=NULL,all=FALSE){
holdsp <- temp[temp$species==allspecies[i],]
+ #Get mean count per survey per year
for (j in 1:nyears){
holdyr <- holdsp[holdsp$yearcode==j,]
@@ -59,12 +84,13 @@ raw.bird.figure <- function(species=NULL,all=FALSE){
}
par(ask=FALSE)
- } else {
+ } else { #Otherwise plot for one species at a time
countmat <-countmat.even <- countmat.uneven <- rep(NA,nyears)
holdsp <- temp[temp$species==species&temp$idmethod!='I',]
+ #Get mean count per survey per year
for (j in 1:nyears){
holdyr <- holdsp[holdsp$yearcode==j,]
diff --git a/figures/figure_resp_summary.R b/figures/figure_resp_summary.R
index 145960d..0f747e8 100644
--- a/figures/figure_resp_summary.R
+++ b/figures/figure_resp_summary.R
@@ -1,4 +1,10 @@
+###################################################################
+## Function to plot a summary of species responses to treatments ##
+###################################################################
+# Arguments:
+# scale: 'mu' for management-unit level, 'hl' for harvest level
+# figmin & figmax: y-limits for figure
resp.summary.figure <- function(scale,ylims,cols,text.cex=1){
@@ -80,5 +86,4 @@ resp.summary.figure <- function(scale,ylims,cols,text.cex=1){
text(mean(x),ylims[2]-1,labels='Positive Response')
text(mean(x),ylims[1]+1,labels='Negative Response')
-}
-
+} \ No newline at end of file
diff --git a/figures/figure_richness.R b/figures/figure_richness.R
index 101e0df..a025b20 100644
--- a/figures/figure_richness.R
+++ b/figures/figure_richness.R
@@ -1,6 +1,14 @@
+############################################
+## Function to plot richness by treatment ##
+############################################
+
+# Arguments:
+# scale: 'mu' for management-unit level, 'hl' for harvest level
+# figmin & figmax: y-limits for figure
richness.figure <- function(scale,figmin,figmax,cols,pchs,ltys,xlab="Year"){
+ #Options specific to scale
if(scale=='mu'){
ntreat <- 3
Rtreat <- Rtreat
@@ -16,6 +24,7 @@ richness.figure <- function(scale,figmin,figmax,cols,pchs,ltys,xlab="Year"){
qu <- function(x){as.numeric(quantile(x,0.975,na.rm=T))}
ql <- function(x){as.numeric(quantile(x,0.025,na.rm=T))}
+ #Calculate means and 95% CIs for each treatment x year
rich.means <- rich.upper <- rich.lower <- matrix(NA,nrow=ntreat,ncol=10)
for (i in 1:ntreat){
rich.means[i,] <- colMeans(Rtreat[,,i])
diff --git a/function_gen_treat_arrays.R b/function_gen_treat_arrays.R
index 56a31f4..36e1b7e 100644
--- a/function_gen_treat_arrays.R
+++ b/function_gen_treat_arrays.R
@@ -1,4 +1,7 @@
-#Function to convert model output to arrays of abundance and richness
+##################################################################################
+## Function to convert model output to summary arrays of abundance and richness ##
+##################################################################################
+
gen.treat.array <- function(jags.object,cov.data,obs.data,species,scale){
#Get necessary information from provided objects
@@ -9,7 +12,6 @@ gen.treat.array <- function(jags.object,cov.data,obs.data,species,scale){
survey.info.sub <- cov.data$survey.info[obs.data$trans[,1],]
area.adjust <- 1.766 #For 75 m radius
- #patch.area.adjust <- 1.1035 #Mean of patch size radii post-harvest
patch.area.adjust <- 1.766 #Mean of patch size radii post-harvest
if(scale=='mu'){
@@ -21,7 +23,7 @@ gen.treat.array <- function(jags.object,cov.data,obs.data,species,scale){
treat.mat <- survey.info.sub[,c('control','clearcut','patch','shelter','singletree')]
}
- #Abundance
+ #Abundance (iteration x year x treatment x species)
Ntreat <- array(NA,dim=c(niter,nyear,ntreat,nspecies))
for (i in 1:(nspecies)){
@@ -44,6 +46,7 @@ gen.treat.array <- function(jags.object,cov.data,obs.data,species,scale){
}
}
+ #Iteration x year x treatment
Rtreat <- array(NA,dim=c(niter,nyear,ntreat))
for (j in 1:nyear){
for (k in 1:niter){
diff --git a/presentations/figures_fscc2016.R b/presentations/figures_fscc2016.R
index ce285d0..7edc9cf 100644
--- a/presentations/figures_fscc2016.R
+++ b/presentations/figures_fscc2016.R
@@ -193,7 +193,7 @@ dev.off()
#Rubus/SCTA Figure
#Read in SCTA data
-birds <- read.csv('data/mistnets_2015.csv',header=T)
+birds <- read.csv('data/hee_mistnets_2015.csv',header=T)
birds$Date <- as.Date(as.character(birds$Date), "%m/%d/%y")
birds.scta <- birds[birds$Species=='Scarlet Tanager',]
@@ -206,7 +206,7 @@ scta.sum$Date <- aggregate(birds.scta$Date,list(Session=birds.scta$Session,
scta.sum <- scta.sum[order(scta.sum$Date),]
#Read in veg data
-veg <- read.csv('data/mistnet_veg.csv',header=T)
+veg <- read.csv('data/hee_mistnet_veg.csv',header=T)
veg$Date <- as.Date(as.character(veg$Date), "%m/%d/%Y")
veg.sort <- veg[order(veg$Date),]
diff --git a/presentations/talk_tws2016.tex b/presentations/talk_tws2016.tex
index db820f5..1aceaa1 100644
--- a/presentations/talk_tws2016.tex
+++ b/presentations/talk_tws2016.tex
@@ -215,18 +215,18 @@
\bigskip
- \includegraphics[width=0.2\paperwidth]{images/hooded_warbler.png}
+ \includegraphics[width=0.2\paperwidth]{images/cerulean_warbler.png}
- Hooded Warbler
+ Cerulean Warbler
\end{column}
\begin{column}{0.48\textwidth}
\centering
- \includegraphics[width=0.2\paperwidth]{images/cerulean_warbler.png}
+ \includegraphics[width=0.2\paperwidth]{images/hooded_warbler.png}
- Cerulean Warbler
+ Hooded Warbler
\bigskip
@@ -344,7 +344,7 @@
\bigskip
- Kellner, K. F.; Ruhl, P. J.; Dunning Jr., J. B.; Riegel, J. K. and Swihart, R. K. \textit{In press.} Multi-scale responses of breeding birds to experimental forest management in Indiana, USA. Forest Ecology and Management. doi: 10.1016/j.foreco.2016.10.008.
+ Kellner, K. F.; Ruhl, P. J.; Dunning Jr., J. B.; Riegel, J. K. and Swihart, R. K. \textit{In press.} Multi-scale responses of breeding birds to experimental forest management in Indiana, USA. Forest Ecology and Management 382: 64-75.
\end{frame}