0

I am in desperate need of help. I’m a PhD candidate and unfortunately, the university has essentially closed for the holidays so there aren’t people around to ask for help.

So I usually work in physiology, but I’m currently working with ecological data, and this is where I’ve become stuck (I’ve been stuck here for over a week). The file I need to read is a ‘.nc’ file which, as far as I can tell, it has 3 dimensions (Latitude, Longitude, and Time[date]) with 7(?) variables.

Excel can’t read it even with the NetCDF4 plug-in. So, I’ve tried putting it into Rstudio and it CAN read it, but just can’t display it to me in any sort of readable manner.

Even when I try and display some variables, nothing comes out in a readable manner.

The data is publically accessible from https://portal.aodn.org.au, and are readings of Alkalinity-Carbon-Salinity-Temperature of the Indian ocean surrounding Western Australia (lat and long co-ordinates) from years 1900 – 2013.

My end goal is to turn this data into a readable excel file so I can begin to analyse it. Any help would be greatly appreciated.

  • 1
    There are lot of datasets in the link which you have shared. Can you link to the specific dataset that you are referring to ? – Ronak Shah Dec 11 '19 at 03:48
  • Based on your description of the data I am assuming you are dealing with a NetCDF file. Try using the `nc_open()` function from the `ncdf4` package. – GordonShumway Dec 11 '19 at 04:15
  • @RonakShah - Unfortunately, there is no link to each set of data. And in each data set, you have to select a polygon of 'lats' and 'longs' the selected polygons of the map. I'm happy to send the nc file over - if there is any way to attach files here? edit: download link. https://processes.aodn.org.au/wps/jobStatus?jobId=45dab9bd-276f-4edf-9a46-c3ab1160dfc7&format=HTML – Jack McElhinney Dec 11 '19 at 05:00
  • So how do you expect the output to look like? The NetCDF file you link to contains data for 7 variables (`ALK`, `DIC`, `OMEGA_A`, `OMEGA_C`, `SSS`, `SST` and `pH_T`) for 1333 time points (you can read the file with e.g. `raster::brick`). How do you want to extract data? Do you want to look at a certain region or specific points in terms of their lat/long? Can you elaborate on what you're trying to do? – Maurits Evers Dec 11 '19 at 05:32
  • Perhaps the following post is helpful for identifying a useful analysis strategy: [Extract time series of a point ( lon, lat) from netCDF in R](https://stackoverflow.com/questions/20621200/extract-time-series-of-a-point-lon-lat-from-netcdf-in-r); there are also a few tutorials on the web that might be interesting to take a closer look at, e.g. [How to extract data from NetCDF files](https://rpubs.com/markpayne/358146), [netCDF in R](http://geog.uoregon.edu/bartlein/courses/geog490/week04-netCDF.html) – Maurits Evers Dec 11 '19 at 05:35
  • thank you @MauritsEvers. And I have no idea - I've never worked with this before! Ideally, I would have spreadsheets of the environmental variables over time in regions of the coastline. Now, I understand this is difficult because these are 3Dimensions. However, I would like to put certain areas (long and lats) into groups of regions, this will allow me to compare it with the other biological data that I have. I'll follow these links and try to see if I can work out a script. – Jack McElhinney Dec 11 '19 at 05:50

0 Answers0