-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathTable_S1.Rmd
More file actions
61 lines (53 loc) · 2.01 KB
/
Table_S1.Rmd
File metadata and controls
61 lines (53 loc) · 2.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
---
title: ""
header-includes:
- \usepackage{caption}
- \captionsetup[figure]{labelformat=empty}
- \captionsetup[table]{labelformat=empty}
- \pagenumbering{gobble}
output:
pdf_document:
latex_engine: xelatex
fig_width: 7
fig_caption: yes
fontsize: 10pt
bibliography: rabbit_refs.bib
csl: journal-of-applied-ecology.csl
classoption:
landscape
---
```{r echo=FALSE, message=FALSE, warning=FALSE, results="asis"}
load("Fitted_rain_model.Rdata")
require(dplyr)
require(xtable)
require(lubridate)
require(knitr)
require(kableExtra)
siteorder<-c("Manangatang", "Cowangie", "Piambie",
"Telopea Downs", "Black Range", "Dunluce",
"Landsborough", "Ararat", "Chatsworth",
"Spring Hill", "Swifts Creek", "Ingliston",
"Pentland Hills", "Rowsley", "Harcourt",
"Yarram", "Skipton", "Lancefield",
"Beechworth", "Yambuk", "Euroa")
trans_summary<-spotlight %>%
mutate(Year=year(Date)) %>%
group_by(Site) %>%
summarise(firstsamp=round(min(Year)),
lastsamp=round(max(Year)),
total_surv=length(Foxes),
years_samped=n_distinct(Year),
maxlength=max(TransectLength)/1000,
meanlength=round(mean(TransectLength)/1000, 2))
names(trans_summary)<-c("Transect", "First Year", "Last Year", "Total Surveys", "Years with Surveys", "Length (km)", "Mean length (km)")
#rename "Yarram/Woodside" to just "Yarram"
trans_summary$Transect <-as.character(trans_summary$Transect)
trans_summary$Transect[trans_summary$Transect=="Yarram/Woodside"] <- "Yarram"
trans_summary$Transect<-factor(trans_summary$Transect, levels=siteorder)
#put sites into rainfall order
trans_summary<-trans_summary %>%
arrange(Transect)
kable(trans_summary, caption="Table S1. Summary statistics for the 21 transects surveyed for abundance of foxes and rabbits. Mean length is the mean transect length actually surveyed across all surveys at each transect. Transects are arranged in order of increasing mean monthly rainfall.",
align=c("c", "c", "c", "c", "c","c", "c", "c") ) %>%
kable_styling(font_size=10)
```