Thanks to the first post of the
series we know
where to observe birds near Radolfzellâ€™s Max Planck Institute for
Ornithology, so we could go and do that! Or we can stay behind our
laptops and take advantage of eBird, a
fantastic bird sightings aggregator! As explained by Matt Strimas-Mackey
in his recent blog post,
â€œThe eBird database currently contains over 500 million records of bird
sightings, spanning every country and over 98% of species, making it an
extremely valuable resource for bird research and conservation.â€�.
Luckily for us, there are no less than two rOpenSci packages giving us
access to eBird data! In this blog post, I shall play with both of them,
highlighting their respective strengths, while discovering what birds
are observed in the area.
How to access eBird data?
There are two ways to access eBird data with an R package for each of
these methods,
whole dataset download via auk maintained by Matt
Strimas-Mackey,
APIs, via rebird maintained by Sebastian
Pardo.
Your use case will help you decide which entry point is the most
appropriate for your use case. Note that both packages have documented
their respective applications in order to help potential users:
rebird README,
auk
README.
You want to study a region, or a bird, quite deeply and you even
want absence/presence data, not only presence data. Use auk!
You want to build a tool based on recent observations only or you
want to get a quick taste of eBirdâ€™s data. Use rebird!
A bit provocatively, do you want birds data only? If not, maybe
youâ€™ll need a combination of auk/rebird and another package.
Check out this list of data providers covered by
spocc, umbrella package
for rOpenSciâ€™s packages accessing occurrence data. Many data sources
actually end up in GBIF
datasets, eBird seems to
upload their data there once a year.
You want to analyze your eBirdâ€™s sightings? Check out the
work-in-progress myebird by
Sebastian Pardo, rebirdâ€™s
maintainer, and this app by SimÃ³n
Valdez-Juarez
and Sebastian Pardo highlighting the
most endangered species you observed.
Youâ€™re writing a birderâ€™s guide to rOpenSci? Use both rebird and
auk to show them off!
How to get access to eBirdâ€™s data
Whole eBird dataset, quarterly updated
One needs to first create an eBird
account and then
request access to the data. Once one
has gotten green light from eBird (in my case a few days following my
request), after a small dance of joy itâ€™s time to head to eBirdâ€™s
download page. If one doesnâ€™t
want nor need to download the whole eBird Basic Dataset (EBD), one can
request a custom download, which I did, asking for only the data for
Germany which I got after a few days (the time to receiving the link to
download a custom dataset is variable). While waiting, I worked on the
rebird part of this post, among other things.
API key? Not yet
At the moment, rebird interfaces the version 1.1 eBird APIs that will
be retired â€œat some point in the
futureâ€�.
When this happens, the rebird package will use the new
API which will mean
youâ€™ll need an API key. Currently, though, you donâ€™t need any
authentication to use rebird.
Using rebird while waiting for the eBirdâ€™s full dataset
In the following, weâ€™ll use the rOpenSciâ€™s package rebird to get and
map all observations in the last 30 days near Radolfzell in Germany.
The Radolfzell part of that sentence is a bit different than in the
last post about finding bird hides near the MPI institute for
ornithology: I
want all observations inside the polygon of the district of Constance
(Landkreis Konstanz, including Radolfzellâ€¦ and a protected natural
area!) so Iâ€™ll first need to get it. For doing that Iâ€™ll use
osmdata::getbb, that uses the free Nominatim API provided by
Openstreetmap.
library(&quot;sf&quot;)
landkreis_konstanz