ResCurve: Computes the residuum between the observed data and the...

Description Usage Arguments Value Examples

View source: R/ResCurve.R

Description

This function computes the residuum of the computed lunar and solar synthesis and the observed data

Usage

1
ResCurve(tcData, obsData)

Arguments

tcData

The results from TideCurve or BuildTC + SynTC. Warning: The synthesis period must overlap with the analysis period. Must be a data.table object. Please see examples.

obsData

The observation data with the columns observation_date, observation_time and height. See attached data for correct formats.

Value

A list with two data.tables with the joined data input and the computed difference between the observed data and the synthesis (res)

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
## Not run: 
#Using TideCurve
tc <- TideCurve(dataInput = tideObservation, asdate = "2015/12/06",
             astime = "00:00:00",      aedate = "2015/12/31",
             aetime = "23:30:00",      ssdate = "2015/12/17",
             sstime = "00:00:00",      sedate = "2015/12/31",
             setime = "23:30:00")
res_tc <- ResCurve(tc, tideObservation)

#Using BuildTC and SynTC
your_model <- BuildTC(dataInput = tideObservation, asdate = "2015/12/06",
             astime = "00:00:00", aedate = "2016/12/31",
             aetime = "23:30:00", keep_data = TRUE)

syn_tc <- SynTC(tmodel = your_model, ssdate = "2015/12/17", sstime = "00:00:00",
sedate = "2015/12/31", setime = "23:30:00")

syn_tc$data_matrix <- your_model$data_matrix

res_tc_n <- ResCurve(syn_tc, tideObservation)


## End(Not run)

TideCurves documentation built on June 28, 2021, 5:17 p.m.