The purpose of this exercise is to analyse point transect survey data: it can sometimes be more difficult than line transect data. In the first problem, the data are simulated and so the true density is known. In the second problem, two different data collection methods were used to survey song birds.
The aim of this practical are to:
dsdata
package.Simulated point transect data from 30 points are given in the text file ‘IntroDS_3Rbras.1.csv’. These data were generated from a half-normal detection function and the true detection function was 79.8 animals/hectare . The perpendicular distances were recorded in metres.
Load the data, check it is OK and plot the perpendicular distances.
library(Distance)
# Read in data
ptdat <- read.csv(file="IntroDS_3Rbras.1.csv", header=TRUE)
# What does the data look like
head(ptdat)
hist(ptdat$distance)
To fit a point transect detection function, the argument transect="point"
needs to be specified:
# Fit half-normal point transect detection function,
ptdat.hn <- ds(data=ptdat, transect="point", key="hn", convert.units=0.01)
The convert.units
argument gives the estimated density in animals per hectare.
The detection function can be plotted as for line transects:
# Plot detection function
plot(ptdat.hn)
To plot the probability density function (pdf), an additional argument is required in the plot
function:
# Plot probability density function
plot(ptdat.hn, pdf=TRUE)
Experiment with keys other than the half normal (i.e. hazard rate and uniform) to assess whether these data can be satisfactorily analysed using the wrong model:
How do the bias and precision compare between models?
A point transect survey of songbirds was conducted at Montrave, Fife, Scotland, in 2004 (Buckland 2006) and for this exercise, the data on winter wrens is used. Several different methods of data collection were used and for this exercise, two point transect methods are used:
For each method the same 32 point transects were used in 33.2 ha of parkland (Fig. 1) and each point transect was visited twice. Detection distances (recorded in metres) were measured with the aid of a rangefinder.
The study site: the dotted line is a small stream, the short dashed lines are tracks and the thick dashed line is a main road. The 32 points, shown by crosses, are laid out on a systematic grid with 100m separation. The diagonal lines were used for a line transect survey.
Access to the data
load("wren1.RData")
You will see that there is an object called wren1
in your R
workspace. There is also a data object available in dsdata
for method 2 (i.e. wren2
) which can be loaded in the same way. Have a look at the wren1
data with
head(wren1, n=3)
Note the Effort
field is 2
meaning each point transect was visited twice. The same applies for wren2
.
What to do:
convert.units=0.01
.Buckland, ST 2006. Point-transect surveys for songbirds: robust methodologies. The Auk 123: 345–57. https://doi.org/10.1642/0004-8038(2006)123[345:PSFSRM]2.0.CO;2.
Solution 3Rbras. Point transect exercises
The code for importing and checking these data and fitting various models is shown below.
library(Distance)
# Read in data
ptdat <- read.csv(file="IntroDS_3Rbras.1.csv", header=T)
# What does data look like
head(ptdat, n=3)
# Fit half-normal detection function, no truncation
ptdat.hn <- ds(data=ptdat, transect="point", key="hn",
convert.units=0.01)
plot(ptdat.hn, pdf=TRUE)
# Try truncation of 20m based on preliminary fit
# Half normal, no adjustments
ptdat.hn.t20m <- ds(data=ptdat, transect="point", key="hn", truncation=20,
convert.units=0.01)
# Hazard rate, no adjustments
ptdat.hr.t20m <- ds(data=ptdat, transect="point", key="hr", truncation=20,
convert.units=0.01)
# Uniform, cosine adjustments
ptdat.uf.cos.t20m <- ds(data=ptdat, transect="point", key="unif",
adjustment="cos", truncation=20,
convert.units=0.01)
DetectionFunction | Adjustments | Truncation | AIC | Density | D.CV | Lower.CI | Upper.CI |
---|---|---|---|---|---|---|---|
Half-nomal | None | 34.2 | 919.1403 | 79.62956 | 0.1256098 | 62.12053 | 102.07360 |
Half-nomal | None | 20.0 | 764.3046 | 70.82577 | 0.1572081 | 51.97829 | 96.50740 |
Hazard rate | None | 20.0 | 767.2114 | 62.36395 | 0.1873007 | 43.20835 | 90.01183 |
Uniform | Cosine | 20.0 | 765.5030 | 75.04383 | 0.1436218 | 56.51495 | 99.64755 |
# Plot probability density functions
par(mfrow=c(2,2))
plot(ptdat.hn, main="Half normal, no truncation", pdf=TRUE)
plot(ptdat.hn.t20m, main="Half normal, truncation 20m", pdf=TRUE)
plot(ptdat.hr.t20m, main="Hazard rate, truncation 20m", pdf=TRUE)
plot(ptdat.uf.cos.t20m, main="Uniform with cosine, truncation 20m", pdf=TRUE)
We see a fair degree of variability between analyses - reliable analysis of point transect data is more difficult than for line transect data. We see greater loss in precision from truncating data relative to line transect sampling, but if we don’t truncate data, different models can give widely differing estimates.
In the code provided below, each dataset is loaded and then detection functions that we selected are fitted.
# Wren data for Method 1 (5 min counts)
load("wren1.RData")
# Wren data for Method 2 (snapshot)
load("wren2.RData")
# Method 1
wren1.uf.cos.t110 <- ds(data=wren1, key="unif", adjustment="cos",
transect="point", truncation=110, convert.units=0.01)
# Method 2
wren2.hr.cos.t110 <- ds(data=wren2, key="hr", adjustment=NULL,
transect="point", truncation=110, convert.units=0.01)
Method | Density | Lower.CI | Upper.CI |
---|---|---|---|
1 | 1.284510 | 0.7894791 | 2.089942 |
2 | 1.023128 | 0.7948734 | 1.316927 |
# Plot detection functions
par(mfrow=c(1,2))
plot(wren1.uf.cos.t110, main="5 minute count")
plot(wren2.hr.cos.t110, main="Snapshot moment")
As the detection distance histograms indicate, winter wren showed evidence of observer avoidance, more than other species in the Montrave study. We show the detection function graph rather than the PDF to emphasise the evasive movement aspect of the data. If you conduct the goodness of fit test, using gof_ds()
, you will find that the models still suitably fit the data.