read_slf_variable: Read slf variables

Description Usage Arguments Value

View source: R/selafin.R

Description

Reads the variables stored in a SELAFIN file (*.slf).

Usage

1
read_slf_variable(fname, seek_start, vars, nv, fsize, npoin, times = NULL)

Arguments

fname

character, name of a SELAFIN file.

seek_start

integer, starting position to read data from the binary file; can be inferred with function read_slf_header.

vars

numeric, vector giving the indices of the variables that shall be read (can be inferred from header information, read_slf_header).

nv

integer giving the total number of variables in the file.

fsize

integer, precision of the values (number of bytes).

npoin

integer, number of mesh points.

times

integer vector, the timesteps to be read. If any specified timestep cannot be found in the file an error is raised. Default (NULL): all.

Value

A list with the following elements:

time

Timesteps in seconds relative to date (element in output of read_slf_header)

values

An array of dimensions (npoin x nv x length(time)) with the values of the variables for each meshpoint and timestep


tpilz/telemac documentation built on Feb. 10, 2022, 2:12 p.m.