get.init.nc: Function that generates a csv file of NetCDF values

View source: R/initGen.R

get.init.ncR Documentation

Function that generates a csv file of NetCDF values

Description

Takes data from a NetCDF file and generates a csv file containing the box-specific values. If the variable is distributed in the vertical then the value on the bottom water layer is returned. This function is useful when collecting data from Atlantis models in order to parameterise new Atlantis models. Incorrect output may be produced if the number of boxes equals the number of time steps or water layers.

Usage

get.init.nc(nc.file, output.file)

Arguments

nc.file

name of the NetCDF file containing the initial conditions.

output.file

name of the csv file where data is written.

Value

Null (always). Produces a csv file with the name ouput.file.

Examples

## Not run: 
nc.file <- "~/Atlantis/RunFiles/SEAP/params/initSEAPaquacult_pH.nc"
output.file <- "oldData.csv" ## where to write the data

get.init.nc(nc.file, output.file) ## extract data from the NetCDF file

## End(Not run)

shanearichards/shinyrAtlantis documentation built on April 10, 2024, 7:19 a.m.