nc_image_stats: Get percent coverage of netCDF satellite image

View source: R/satfile_funcs.R

nc_image_statsR Documentation

Get percent coverage of netCDF satellite image

Description

Given a filename, W/E/S/N boundaries, and a variable name, check the percent coverage for that variable within the boundaries.

Usage

nc_image_stats(
  file,
  w,
  e,
  s,
  n,
  var = "geophysical_data/Rrs_555",
  latvar = "navigation_data/latitude",
  lonvar = "navigation_data/longitude"
)

Arguments

file

String, netCDF filename

w, e, s, n

Numeric values, west/east/south/north in decimal degrees

var

String, name of variable to check for percent coverage (full path to the variable within the netCDF, e.g. geophysical_data/Rrs_555)

latvar

String, full path and name of the latitude variable

lonvar

String, full path and name of the longitude variable

Value

Dataframe containing filename, number of valid pixels, total number of pixels, and percent coverage. If file can't be read, "try-error" is returned instead.


BIO-RSG/oceancolouR documentation built on April 25, 2024, 12:28 p.m.