The hardware and bandwidth for this mirror is donated by METANET, the Webhosting and Full Service-Cloud Provider.
If you wish to report a bug, or if you are interested in having us mirror your free-software or open-source project, please feel free to contact us at mirror[@]metanet.ch.

Getting started with toeclim

What is time of emergence?

Climate records combine a slowly evolving forced signal (for example greenhouse-gas driven warming) with internal variability (weather, ENSO, decadal oscillations). The time of emergence (ToE) is the moment the signal becomes large relative to that variability, so that a change can be told apart from natural fluctuations (Hawkins and Sutton, 2012).

toeclim implements a transparent, configurable version of this idea and attaches uncertainty to it:

  1. estimate a smooth signal relative to a baseline mean;
  2. estimate noise from a baseline period;
  3. declare emergence when the signal-to-noise ratio exceeds k for at least persist consecutive years (optionally through to the end of the record);
  4. bootstrap the residuals to see how much of the answer is just noise.

A single series

d <- toe_simulate(n_years = 150, slope = 0.03, onset = 1970,
                  sigma = 0.3, phi = 0.5, seed = 10)
head(d, 3)
#>   year forced   member_01
#> 1 1900      0 -0.03289004
#> 2 1901      0  0.09251191
#> 3 1902      0 -0.22392926

The forced response is flat until 1970 and then warms at 0.03 units per year, so the true signal is known.

toe_trend(d$member_01, d$year)
#> Sen's slope / Mann-Kendall trend test
#>   n = 150 
#>   Slope: 0.01612 per unit time,  95 % CI [ 0.01409, 0.01814 ]
#>   Mann-Kendall: S = 8584 , Z = 14.1 , p = <2e-16 
#>   Lag-1 autocorrelation (detrended): 0.803 -> trend-free prewhitening applied
fit <- toe_emerge(d$member_01, d$year, baseline = c(1900, 1950),
                  n_boot = 200, seed = 1)
fit
#> Time of emergence
#>   Signal: quadratic | threshold k = 2 | persistence = 5 (window)
#>   Baseline: 1900-1950 | noise (baseline) sigma = 0.281
#>   ToE: 1993 
#>   Bootstrap (ar1, n = 200): 90% interval [1983.95, 2001.00], 100% of replicates emerge
plot(fit)

The shaded orange band is the bootstrap interval for the emergence year. The grey band shows the baseline mean plus or minus k noise standard deviations.

How likely is emergence by a given date?

toe_prob(fit, times = c(1990, 2000, 2010, 2020))
#>   time prob
#> 1 1990 0.39
#> 2 2000 0.94
#> 3 2010 1.00
#> 4 2020 1.00

Sensitivity to subjective choices

The threshold k and the persistence requirement are choices, not physics. toe_sensitivity() shows how much they matter.

toe_sensitivity(d$member_01, d$year, baseline = c(1900, 1950),
                k = c(1, 2, 3), persist = c(1, 5, 10))
#>   k persist  toe
#> 1 1       1 1980
#> 2 2       1 1993
#> 3 3       1 2004
#> 4 1       5 1980
#> 5 2       5 1993
#> 6 3       5 2004
#> 7 1      10 1980
#> 8 2      10 1993
#> 9 3      10 2004

Ensembles

For large ensembles, apply the method to every member and inspect the spread. The bundled toe_example data set has ten synthetic members.

members <- toe_example[, grep("^member", names(toe_example))]
ens <- toe_ensemble(members, toe_example$year, baseline = c(1900, 1960))
ens
#> Ensemble time of emergence (10 members)
#>   Emerged: 10 / 10
#>   Median ToE: 1998.5  | range: 1988 - 2015  | 5-95%: 1989 - 2015 
#>   Pooled (ensemble-mean signal): 2001
plot(ens)

The pooled estimate uses the ensemble-mean signal, which has little noise of its own, against the typical single-realisation noise. It is usually earlier than most members: the ensemble mean reveals the forced response before any single realisation can.

Preparing real data

Monthly data can be converted to seasonal-cycle-free anomalies and then to annual means:

dates <- seq(as.Date("1950-01-01"), as.Date("2019-12-01"), by = "month")
mon <- as.integer(format(dates, "%m"))
yr  <- as.integer(format(dates, "%Y"))
x <- 12 + 8 * sin(2 * pi * mon / 12) + 0.02 * pmax(0, yr - 1980) +
  rnorm(length(dates), sd = 0.8)

anom   <- toe_anomaly(x, dates, baseline = c(1950, 1979), by = "month")
annual <- toe_annual(anom$anomaly, dates)
head(annual, 3)
#>   year     value  n
#> 1 1950 0.1252714 12
#> 2 1951 0.1423281 12
#> 3 1952 0.2366975 12
toe_emerge(annual$value, annual$year, baseline = c(1950, 1979))
#> Time of emergence
#>   Signal: quadratic | threshold k = 2 | persistence = 5 (window)
#>   Baseline: 1950-1979 | noise (baseline) sigma = 0.244
#>   ToE: 2007

Notes and limitations

References

Hawkins, E. and Sutton, R. (2012). Time of emergence of climate signals. Geophysical Research Letters, 39, L01702. doi:10.1029/2011GL050087

Yue, S., Pilon, P., Phinney, B. and Cavadias, G. (2002). The influence of autocorrelation on the ability to detect trend in hydrological series. Hydrological Processes, 16, 1807-1829. doi:10.1002/hyp.1095

These binaries (installable software) and packages are in development.
They may not be fully stable and should be used with caution. We make no claims about them.