Data Wrangling to Assess Data Availability: A Data Detective at Work

By Alexa Kownacki, Ph.D. Student, OSU Department of Fisheries and Wildlife, Geospatial Ecology of Marine Megafauna Lab

Data wrangling, in my own loose definition, is the necessary combination of both data selection and data collection. Wrangling your data requires accessing then assessing your data. Data collection is just what it sounds like: gathering all data points necessary for your project. Data selection is the process of cleaning and trimming data for final analyses; it is a whole new bag of worms that requires decision-making and critical thinking. During this process of data wrangling, I discovered there are two major avenues to obtain data: 1) you collect it, which frequently requires an exorbitant amount of time in the field, in the lab, and/or behind a computer, or 2) other people have already collected it, and through collaboration you put it to a good use (often a different use then its initial intent). The latter approach may result in the collection of so much data that you must decide which data should be included to answer your hypotheses. This process of data wrangling is the hurdle I am facing at this moment. I feel like I am a data detective.

Data wrangling illustrated by members of the R-programming community. (Image source: R-bloggers.com)

My project focuses on assessing the health conditions of the two ecotypes of bottlenose dolphins between the waters off of Ensenada, Baja California, Mexico to San Francisco, California, USA between 1981-2015. During the government shutdown, much of my data was inaccessible, seeing as it was in possession of my collaborators at federal agencies. However, now that the shutdown is over, my data is flowing in, and my questions are piling up. I can now begin to look at where these animals have been sighted over the past decades, which ecotypes have higher contaminant levels in their blubber, which animals have higher stress levels and if these are related to geospatial location, where animals are more susceptible to human disturbance, if sex plays a role in stress or contaminant load levels, which environmental variables influence stress levels and contaminant levels, and more!

Alexa, alongside collaborators, photographing transiting bottlenose dolphins along the coastline near Santa Barbara, CA in 2015 as part of the data collection process. (Image source: Nick Kellar).

Over the last two weeks, I was emailed three separate Excel spreadsheets representing three datasets, that contain partially overlapping data. If Microsoft Access is foreign to you, I would compare this dilemma to a very confusing exam question of “matching the word with the definition”, except with the words being in different languages from the definitions. If you have used Microsoft Access databases, you probably know the system of querying and matching data in different databases. Well, imagine trying to do this with Excel spreadsheets because the databases are not linked. Now you can see why I need to take a data management course and start using platforms other than Excel to manage my data.

A visual interpretation of trying to combine datasets being like matching the English definition to the Spanish translation. (Image source: Enchanted Learning)

In the first dataset, there are 6,136 sightings of Common bottlenose dolphins (Tursiops truncatus) documented in my study area. Some years have no sightings, some years have fewer than 100 sightings, and other years have over 500 sightings. In another dataset, there are 398 bottlenose dolphin biopsy samples collected between the years of 1992-2016 in a genetics database that can provide the sex of the animal. The final dataset contains records of 774 bottlenose dolphin biopsy samples collected between 1993-2018 that could be tested for hormone and/or contaminant levels. Some of these samples have identification numbers that can be matched to the other dataset. Within these cross-reference matches there are conflicting data in terms of amount of tissue remaining for analyses. Sorting these conflicts out will involve more digging from my end and additional communication with collaborators: data wrangling at its best. Circling back to what I mentioned in the beginning of this post, this data was collected by other people over decades and the collection methods were not standardized for my project. I benefit from years of data collection by other scientists and I am grateful for all of their hard work. However, now my hard work begins.

The cutest part of data wrangling: finding adorable images of bottlenose dolphins, photographed during a coastal survey. (Image source: Alexa Kownacki).

There is also a large amount of data that I downloaded from federally-maintained websites. For example, dolphin sighting data from research cruises are available for public access from the OBIS (Ocean Biogeographic Information System) Sea Map website. It boasts 5,927,551 records from 1,096 data sets containing information on 711 species with the help of 410 collaborators. This website is incredible as it allows you to search through different data criteria and then download the data in a variety of formats and contains an interactive map of the data. You can explore this at your leisure, but I want to point out the sheer amount of data. In my case, the OBIS Sea Map website is only one major platform that contains many sources of data that has already been collected, not specifically for me or my project, but will be utilized. As a follow-up to using data collected by other scientists, it is critical to give credit where credit is due. One of the benefits of using this website, is there is information about how to properly credit the collaborators when downloading data. See below for an example:

Example citation for a dataset (Dataset ID: 1201):

Lockhart, G.G., DiGiovanni Jr., R.A., DePerte, A.M. 2014. Virginia and Maryland Sea Turtle Research and Conservation Initiative Aerial Survey Sightings, May 2011 through July 2013. Downloaded from OBIS-SEAMAP (http://seamap.env.duke.edu/dataset/1201) on xxxx-xx-xx.

Citation for OBIS-SEAMAP:

Halpin, P.N., A.J. Read, E. Fujioka, B.D. Best, B. Donnelly, L.J. Hazen, C. Kot, K. Urian, E. LaBrecque, A. Dimatteo, J. Cleary, C. Good, L.B. Crowder, and K.D. Hyrenbach. 2009. OBIS-SEAMAP: The world data center for marine mammal, sea bird, and sea turtle distributions. Oceanography 22(2):104-115

Another federally-maintained data source that boasts more data than I can quantify is the well-known ERDDAP website. After a few Google searches, I finally discovered that the acronym stands for Environmental Research Division’s Data Access Program. Essentially, this the holy grail of environmental data for marine scientists. I have downloaded so much data from this website that Excel cannot open the csv files. Here is yet another reason why young scientists, like myself, need to transition out of using Excel and into data management systems that are developed to handle large-scale datasets. Everything from daily sea surface temperatures collected on every, one-degree of latitude and longitude line from 1981-2015 over my entire study site to Ekman transport levels taken every six hours on every longitudinal degree line over my study area. I will add some environmental variables in species distribution models to see which account for the largest amount of variability in my data. The next step in data selection begins with statistics. It is important to find if there are highly correlated environmental factors prior to modeling data. Learn more about fitting cetacean data to models here.

The ERDAPP website combined all of the average Sea Surface Temperatures collected daily from 1981-2018 over my study site into a graphical display of monthly composites. (Image Source: ERDDAP)

As you can imagine, this amount of data from many sources and collaborators is equal parts daunting and exhilarating. Before I even begin the process of determining the spatial and temporal spread of dolphin sightings data, I have to identify which data points have sex identified from either hormone levels or genetics, which data points have contaminants levels already quantified, which samples still have tissue available for additional testing, and so on. Once I have cleaned up the datasets, I will import the data into the R programming package. Then I can visualize my data in plots, charts, and graphs; this will help me identify outliers and potential challenges with my data, and, hopefully, start to see answers to my focal questions. Only then, can I dive into the deep and exciting waters of species distribution modeling and more advanced statistical analyses. This is data wrangling and I am the data detective.

What people may think a ‘data detective’ looks like, when, in reality, it is a person sitting at a computer. (Image source: Elder Research)

Like the well-known phrase, “With great power comes great responsibility”, I believe that with great data, comes great responsibility, because data is power. It is up to me as the scientist to decide which data is most powerful at answering my questions.

Data is information. Information is knowledge. Knowledge is power. (Image source: thedatachick.com)

 

Science (or the lack thereof) in the Midst of a Government Shutdown

By Alexa Kownacki, Ph.D. Student, OSU Department of Fisheries and Wildlife, Geospatial Ecology of Marine Megafauna Lab

In what is the longest government shutdown in the history of the United States, many people are impacted. Speaking from a scientist’s point of view, I acknowledge the scientific community is one of many groups that is being majorly obstructed. Here at the GEMM Laboratory, all of us are feeling the frustrations of the federal government grinding to a halt in different ways. Although our research spans great distances—from Dawn’s work on New Zealand blue whales that utilizes environmental data managed by our federal government, to new projects that cannot get federal permit approvals to state data collection, to many of Leigh’s projects on the Oregon coast of the USA that are funded and collaborate with federal agencies—we all recognize that our science is affected by the shutdown. My research on common bottlenose dolphins is no exception; my academic funding is through the US Department of Defense, my collaborators are NOAA employees who contribute NOAA data; I use publicly-available data for additional variables that are government-maintained; and I am part of a federally-funded public university. Ironically, my previous blog post about the intersection of science and politics seems to have become even more relevant in the past few weeks.

Many graduate students like me are feeling the crunch as federal agencies close their doors and operations. Most people have seen the headlines that allude to such funding-related issues. However, it’s important to understand what the funding in question is actually doing. Whether we see it or not, the daily operations of the United States Federal government helps science progress on a multitude of levels.

Federal research in the United States is critical. Most governmental branches support research with the most well-known agencies for doing so being the National Science Foundation (NSF), the US Department of Agriculture (USDA), the National Oceanic and Atmospheric Administration (NOAA), and the National Aeronautics and Space Administration. There are 137 executive agencies in the USA (cei.org). On a finer scale, NSF alone receives approximately 40,000 scientific proposals each year (nsf.gov).

If I play a word association game and I am given the word “science”, my response would be “data”. Data—even absence data—informs science. The largest aggregate of metadata with open resources lives in the centralized website, data.gov, which is maintained by the federal government and is no longer accessible and directs you to this message:Here are a few more examples of science that has stopped in its track from lesser-known research entities operated by the federal government:

Currently, the National Weather Service (NWS) is unable to maintain or improve its advanced weather models. Therefore, in addition to those of us who include weather or climate aspects into our research, forecasters are having less and less information on which to base their weather predictions. Prior to the shutdown, scientists were changing the data format of the Global Forecast System (GFS)—the most advanced mathematical, computer-based weather modeling prediction system in the USA. Unfortunately, the GFS currently does not recognize much of the input data it is receiving. A model is only as good as its input data (as I am sure Dawn can tell you), and currently that means the GFS is very limited. Many NWS models are upgraded January-June to prepare for storm season later in the year. Therefore, there are long-term ramifications for the lack of weather research advancement in terms of global health and safety. (https://www.washingtonpost.com/weather/2019/01/07/national-weather-service-is-open-your-forecast-is-worse-because-shutdown/?noredirect=on&utm_term=.5d4c4c3c1f59)

An example of one output from the GFS model. (Source: weather.gov)

The Food and Drug Administration (FDA)—a federal agency of the Department of Health and Human Services—that is responsible for food safety, has reduced inspections. Because domestic meat and poultry are at the highest risk of contamination, their inspections continue, but by staff who are going without pay, according to the agency’s commissioner, Dr. Scott Gottlieb. Produce, dry foods, and other lower-risk consumables are being minimally-inspected, if at all.  Active research projects investigating food-borne illness that receive federal funding are at a standstill.  Is your stomach doing flips yet? (https://www.nytimes.com/2019/01/09/health/shutdown-fda-food-inspections.html?rref=collection%2Ftimestopic%2FFood%20and%20Drug%20Administration&action=click&contentCollection=timestopics&region=stream&module=stream_unit&version=latest&contentPlacement=2&pgtype=collection)

An FDA field inspector examines imported gingko nuts–a process that is likely not happening during the shutdown. (Source: FDA.gov)

The National Parks Service (NPS) recently made headlines with the post-shutdown acts of vandalism in the iconic Joshua Tree National Park. What you might not know is that the shutdown has also stopped a 40-year study that monitors how streams are recovering from acid rain. Scientists are barred from entering the park and conducting sampling efforts in remote streams of Shenandoah National Park, Virginia. (http://www.sciencemag.org/news/2019/01/us-government-shutdown-starts-take-bite-out-science)

A map of the sampling sites that have been monitored since the 1980s for the Shenandoah Watershed Study and Virginia Trout Stream Sensitivity Study that cannot be accessed because of the shutdown. (Source: swas.evsc.virginia.edu)

NASA’s Stratospheric Observatory for Infrared Astronomy (SOFIA), better known as the “flying telescope” has halted operations, which will require over a week to bring back online upon funding restoration. SOFIA usually soars into the stratosphere as a tool to study the solar system and collect data that ground-based telescopes cannot. (http://theconversation.com/science-gets-shut-down-right-along-with-the-federal-government-109690)

NASA’s Stratospheric Observatory for Infrared Astronomy (SOFIA) flies over the snowy Sierra Nevada mountains while the telescope gathers information. (Source: NASA/ Jim Ross).

It is important to remember that science happens outside of laboratories and field sites; it happens at meetings and conferences where collaborations with other great minds brainstorm and discover the best solutions to challenging questions. The shutdown has stopped most federal travel. The annual American Meteorological Society Meeting and American Astronomical Society meeting were two of the scientific conferences in the USA that attract federal employees and took place during the shutdown. Conferences like these are crucial opportunities with lasting impacts on science. Think of all the impressive science that could have sparked at those meetings. Instead, many sessions were cancelled, and most major agencies had zero representation (https://spacenews.com/ams-2019-overview/). Topics like lidar data applications—which are used in geospatial research, such as what the GEMM Laboratory uses in some its projects, could not be discussed. The cascade effects of the shutdown prove that science is interconnected and without advancement, everyone’s research suffers.

It should be noted, that early-career scientists are thought to be the most negatively impacted by this shutdown because of financial instability and job security—as well as casting a dark cloud on their futures in science: largely unknown if they can support themselves, their families, and their research. (https://eos.org/articles/federal-government-shutdown-stings-scientists-and-science). Graduate students, young professors, and new professionals are all in feeling the pressure. Our lives are based on our research. When the funds that cover our basic research requirements and human needs do not come through as promised, we naturally become stressed.

An adult and a juvenile common bottlenose dolphin, forage along the San Diego coastline in November 2018. (Source: Alexa Kownacki)

So, yes, funding—or the lack thereof—is hurting many of us. Federally-funded individuals are selling possessions to pay for rent, research projects are at a standstill, and people are at greater health and safety risks. But, also, science, with the hope for bettering the world and answering questions and using higher thinking, is going backwards. Every day without progress puts us two days behind. At first glance, you may not think that my research on bottlenose dolphins is imperative to you or that the implications of the shutdown on this project are important. But, consider this: my study aims to quantify contaminants in common bottlenose dolphins that either live in nearshore or offshore waters. Furthermore, I study the short-term and long-term impacts of contaminants and other health markers on dolphin hormone levels. The nearshore common bottlenose dolphin stocks inhabit the highly-populated coastlines that many of us utilize for fishing and recreation. Dolphins are mammals, that respond to stress and environmental hazards, in similar ways to humans. So, those blubber hormone levels and contamination results, might be more connected to your health and livelihood than at first glance. The fact that I cannot download data from ERDDAP, reach my collaborators, or even access my data (that starts in the early 1980s), does impact you. Nearly everyone’s research is connected to each other’s at some level, and that, in turn has lasting impacts on all people—scientists or not. As the shutdown persists, I continue to question how to work through these research hurdles. If anything, it has been a learning experience that I hope will end soon for many reasons—one being: for science.

How to apply my PhD?

By Leila Lemos, PhD candidate, Fisheries and Wildlife Department

Time has flown. It seems that it was like a month ago that I received the news that I was approved in a public notice from the Brazilian government to study abroad, and began the process of moving to Oregon. But actually almost three years have now passed, and I am starting to wrap up my PhD, since I need to defend it in a little bit more than a year.

Our team is now starting the third and last fieldwork season for my PhD project. I am also working on my study plan to determine the last classes I need to take, and our first manuscripts are ‘in press’ or ‘in prep’ for submission to journals. So, it’s time for me to think about what comes next.

I am from Rio de Janeiro, Brazil, and I am studying in the US through a Brazilian government program called Science Without Borders. This program aims to send students abroad to learn new techniques and to develop innovative projects. The projects needed to be original to be approved by the public notice. The main idea is to bring these students back to Brazil, after their PhD completion, to disseminate the acquired knowledge by applying the learned techniques.

My project includes a few novel aspects that allowed for funding by this program. The main focus of my thesis is to develop an endocrinology study of a cetacean species. This was (and still is) a critical field in Brazil, as reported by the “National Action Plan for the conservation of aquatic mammals: Small cetaceans” (2010). According to this Action Plan, cetacean hormonal analyses are rare and of high priority, but there are limited labs with the capacity to study cetacean endocrinology in Brazil. Other limiting factors are the associated analysis costs and a lack of human knowledge and skills. In addition to the hormonal analyses (Figure 1), I am also using other ‘new technologies’ in the project: drones (Figure 2; Video 1) and GoPros (Video 2).

Figure 1: Learning how to perform hormonal analysis at the Seattle Aquarium, WA.
Source: Angela Smith

 

Figure 2: Learning how to fly a drone in Newport, OR.
Source: Florence Sullivan

 

Video 1: Drone flights performed in Newport, OR, during fieldwork in 2016.

* Taken under NOAA/NMFS permit #16111 to John Calambokidis.

 

Video 2: Video of mysid swarms during a GoPro deployment conducted in Port Orford, OR, during fieldwork in 2016.

 

The importance of studying cetacean hormones includes a better understanding of their reproductive cycles (i.e., sex hormones such as progesterone, testosterone and estradiol) and their physiological stress response (i.e., cortisol) to possible threats (e.g., acoustic pollution, contaminants, lack of prey). In addition, through photographs and videos recorded by drones we can conduct photogrammetry analysis to monitoring cetacean body condition, and through GoPro recordings of the water column we can assess prey availability. Changes in both body condition and prey can help us explaining how and why hormone levels vary.

Through my PhD I have obtained skills in hormone analysis, photogrammetry and video prey assessment by studying the logistically accessible and non-threatened gray whale (Eschrichtius robustus). During method development, these features are important to increase sample size and demonstrate feasibility. But now that the methodologies have proven successful, we can start applying them to other species and regions, and under different circumstances, to improve conservation efforts of threatened populations.

Many cetacean species along the Brazilian coast are threatened, particularly from fishing gear and vessel interactions, chemical and noise pollution. By applying the methods we have developed in the GEMM Lab during my PhD to cetacean conservation issues in Brazil, we could enable a great expansion in knowledge across many fields (i.e., endocrinology, behavior, photogrammetry, diet). Additionally, these skills can promote safer work environments (for the scientist and for the object of study) and cheaper work processes. However, many countries, such as Brazil, do not have the infrastructure and access to technologies to conduct these same analyses, as in developed countries like the USA. These technologies, when sold in Brazil, have many taxes on the top of the product that they can become an extra hurdle, due to budget constraints. Thus, there is a need for researchers to adapt these skills and technologies, in the best manner possible, to the reality of the country.

Now that I am starting to think about ‘life after PhD’, I can see myself returning to my country to spread the knowledge, technologies and skills I have gained through these years at OSU to new research projects so that I am able to assist with conservation efforts for the ocean and marine fauna in Brazil.

 

References:

PAN, 2010. Plano de ação nacional para a conservação dos mamíferos aquáticos: pequenos cetáceos / André Silva Barreto … [et al.]; organizadores Claudia Cavalcante Rocha-Campos, Ibsen de Gusmão Câmara, Dan Jacobs Pretto. – Brasília: Instituto Chico Mendes de Conservação da Biodiversidade, Icmbio, 132 p. Em: <http://www.icmbio.gov.br/portal/images/ stories/docs-plano-de-acao/pan-peqs-cetaceos/pan_pequenoscetaceos_web.pdf> Acessado em: 27 de Maio de 2015.