plotSum: An evolution of 'greenProcess' for the combination of...

Description Usage Arguments Details Value Author(s) Examples

View source: R/plotSum.R

Description

The combineUncertainty uses greenProcess to fit all available double logistic equations in the phenopix package and extracts thresholds with all available methods. Then uncertainties can be combined and returned by using summarizePhases and plotted with plotSum. See greenProcess.

Usage

1

Arguments

ts

A ts or zoo object with gcc data. index(ts) must be numeric days of year (doys) or a POSIXct vector

sum

An object in output from summarizePhases

which

One between trs, derivatives, klosterman, gu

v

An optional vector of vertical coordinates (in y-axis unit for plot annotation of phase names)

quantile

If TRUE, the plotted uncertainty envelope is based on the quantiles, and not min-max, otherwise min-max envelope is plotted

...

For the plotting function, a number of parameters from generic plot can be specified. Note that graphic properties of fitted lines and thresholds cannot be modified. See examples.

Details

This function uses greenProcess to fit all available double logistic equations in the phenopix package and extracts thresholds with all available methods. Then uncertainties can be combined and returned by using summarizePhases and plotted with plotSum. See greenProcess, summarizePhases, plotSum. This function uses a modellistic approach to combine all uncertainties from all available phenopix fittings, as to get an ensemble of phases with different methods, without necessarily choosing any of them.

Value

A named list with dataframes for each phenophase method with all replication for each of the included fitting methods. These data can then be combined with the companion functions summarizePhases and plotSum. See examples for details.

Author(s)

Gianluca Filippa <gian.filippa@gmail.com>

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
## Not run: 
  require(zoo) 
  data(bartlett2009.filtered)
  combined.fit <- combineUncertainty(na.approx(filtered.tmp$max.filtered), nrep=100)
# 100 replications for each fitting
  names(combined.fit) # a dataframe for each phenoMethod + a list with all fittings
  fit.summary <- summarizePhases(combined.fit, across.methods=TRUE)
## again a list with one element for each fitting method + two additional items 
## if across.methods is TRUE, which combines gu + klosterman phenophase methods 
## in a single method, and the same happens for trs and derivatives
  plotSum(bartlett2009.filtered, fit.summary, which='klosterman')
## a plot with original timeseries + phenophases and their uncertainty
  
## End(Not run)
  

phenopix documentation built on May 2, 2019, 4:50 p.m.