results: Results object

Description Usage Arguments Value Note

View source: R/results.R

Description

Initialise a results object to handle the results of TELEMAC-2D runs.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
results(x, ...)

## Default S3 method:
results(x = NULL, fname = "results.slf", ...)

## S3 method for class 'character'
results(x, fname = NULL, log = NULL, ...)

## S3 method for class 't2d_res'
results(x, fname = NULL, log = NULL, ...)

## S3 method for class 't2d'
results(x, ...)

## S3 method for class 't2d_res'
print(x, ..., n = 10)

Arguments

x

Either: NULL (default), in which case a simple template without data will be generated; a character string providing the name of an existing results file; an object of class t2d_res (modify attributes); an object of class t2d (read data after model run).

...

Arguments passed to or from other methods, e.g. to read_results such as arguments vars, times, or return_datetime.

fname

character, name for the associated results file (can also be used to replace an existing entry).

log

File name of a log file from a simulation run, if it exists.

n

Maximum number of steering parameters to print.

Value

An object of class t2d_res consisting of an attribute file pointing to a specific results file, an attribute log pointing to the log of a simulation run, and a list with elements

header

General information including title, precision (of numbers in the slf file in bytes), the numbers of mesh elements and points, the number of points per mesh (3 in case of triangles which is the only supported value for now), the variable names and units, and the simulation start date.

tin

An object of class t2d_tin representing the underlying mesh.

log

The log messages (a character vector).

values

A data.frame where each line represents the value for a certain mesh point (with coordinates x and y) at a certain simulation timestep (note that this might be difficult to interpret if you used variable timestep lengths) for a specific variable.

Note

Also note the associated plot.t2d_res method.


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