Posted on

Birding in R

Birding is the activity of observing birds, either with the naked eye or through visual enhancement devices like binoculars or a telescope. It also includes photographing birds and submitting observations to public databases.

My students learn biology, ecology, taxonomy, and even musculoskeletal and digestive systems while learning to see the little things in nature. They also develop a passion for birds and become lifelong learners.

Using eBird data

eBird is a global network of birders who submit observations to a central database. The straightforward data collection protocols and participation incentives engage large numbers of observers. The resulting data are valuable for species that are difficult to monitor using other techniques. However, eBird data contain significant levels of noise, and these must be carefully accounted for during data analysis.

Several R packages provide access to eBird data. Some, like auk and rebird, provide access to the full set of eBird observations, while others focus on specific types of analyses (e.g. presence-absence). These packages may be used with other tools for managing bird data, such as scrubr, which cleans biological occurrence records and is part of the rOpenSci suite.

The open eBird status and trends data products can be useful for strategic conservation planning, scientific modeling, and analyzing data from land trust hotspots. To access eBird status and trends information, first fill out the eBird data request form. This allows eBird to keep track of the number of people using the data and learn about the ways in which it is being applied.

Using Shiny

The Shiny application framework has made it easier for R users to build interactive web applications. It provides automatic reactive binding between inputs and outputs, making it easy to create a complex visualization in a few steps.

This is a template for a minimal Shiny app that doesn’t do much. You should copy this into a new folder named app.R and save it in RStudio. It is important that you follow the naming conventions for the files, or else RStudio won’t recognize it as a Shiny app.

This example uses the DT package to replace Shiny’s default table output with something more visually appealing. This is because Shiny’s default tables look very basic and are often hard to read. DT’s dataTableOutput() + renderTable() function is a great way to get around this problem. This function takes a comma-separated list of inputs and returns a beautiful data table. It also supports many other features that you can use to add interactivity to your app.

Using the BIRDS package

The BIRDS package is a set of tools for reviewing biodiversity data to understand the process that generated them. It takes a systematic approach to review the occurrence data, and provides summaries that inform about sampling effort (or data completeness). It also includes information on the spatial distribution of the data.

The vignette on the BIRDs website walks through the most important functions of the package, with examples and a workflow to help guide your decisions. The package also has a brief introduction video.

Modern birders are spoiled for choice when it comes to submitting their sightings. One of the most popular is eBird, developed by the Cornell Lab of Ornithology. This platform lets birders report the species they see and where they saw them. The resulting data is available to researchers, and helps them track bird populations over time.

Using a Shiny application

Shiny is an open-source package from RStudio that allows you to build interactive web applications without having knowledge of HTML and JavaScript. These apps can be used to visualize data, facilitate remote collaboration, and share results with others. They can be hosted on the web or embedded in R Markdown documents. Depending on the configuration, they can be displayed in a web browser or in RStudio’s built-in viewer pane.

Shiny apps are made up of two components: the UI and the server. The UI is the web page that users interact with, while the server processes R commands and updates the UI. The server runs on the computer that hosts the app, usually 127.0.0.1 (also known as localhost).

To create a shiny app, you must source both the ui and the server files. Then, call the function shineApp(ui, server) to create the application. Once the application is ready, you can publish it using rsconnect. Then, users can access your app by entering the URL in a web browser.

Return to the home screen

About The Author

Leave a Reply

Your email address will not be published. Required fields are marked *