Time Shifting Time Series Data

In many cases, you will want to use historic data to populate a Time Series. Having done so, you then want to apply that historic data to your simulation (which likely looks forward in time). In order to do this, therefore, you need to time shift the data so that the historic data is applied in an appropriate and consistent manner.

To support this, GoldSim provides an option to time shift a data series in an appropriate manner. This feature is provided in the “Advanced” section of the Time Series dialog, accessed via the More button:

If you check Enable Time Shifting of Time Series Data, the Settings... button becomes available, providing access to this dialog (in fact, when you first check the Time Shifting box, this dialog opens automatically):

Note: Time shifting is not available if the input represents a “Change over the next time interval”, a “Change over the previous time interval” or a “Discrete Change”.

GoldSim provides two different ways that Time Series can be shifted.

The first option is to Use random starting point. This option randomly samples a starting point in the data set for each realization A single model run within a Monte Carlo simulation. It represents one possible path the system could follow through time.. This is useful, for example, if you have 50 years of rainfall data, you want to carry out a 1 year simulation, and you want GoldSim to randomly sample a different historic year for each realization.

The manner in which GoldSim randomly samples the starting point in a data set is controlled by two things:

The behavior is summarized below:

Note: When specifying time shifting using annual periodicity, your time series should contain at least 366 days of data.
Note: The random sampling also takes into account the amount of data. For example, if you had 1000 days of data and selected “annual” Data periodicity, the probability of picking the first two years for the starting point would be (365/1000), while the probability of picking the last year would be only (270/1000). In this example, in order to have equal probability of picking any year as a starting point, you would require three full years of data.

The second option for time shifting Time Series is to Shift data years to align with simulation dates. This option is only available if the Time Series data is specified using Calendar Time.

This option shifts the time series data forward (or backward) by a multiple of a year such that the simulation begins by using data from the specified Data year to start in. For example, if the actual data set started on 31 July1989 and ended on 31 December 2011, the Simulation Start Date was 1 January 2013, and the Data year to start in was entered as 1990, GoldSim would treat the data set such that the data point corresponding to 1 January 1990 would be used for 1 January 2013 (and, assuming daily data was entered, the data point for 2 January 1990 would be used for 2 January 2013, etc.).

This is useful, for example, if you wish to apply historic data to a forward-looking simulation, assuming no uncertainty or randomness. That is, this option assumes that with regard to the Time Series, the future will be exactly the same as the past (as represented by the historic data).

Note: If you wanted to account for uncertainty and randomness while still directly using historic data, you could do so by entering multiple years of data, and then using the Use random starting point option with “annual periodicity”.

In order to better understand how this works, the table below summarizes how the data would be shifted under various conditions. For this table, it is assumed that the actual time series data range is from 31 July 1989 to 31 December 2011, and the Simulation Start Date is 1 January 2013:

Specified “Data year to start in” Data point used to represent 1 January 2013 Comment
1990 1 January 1990
1995 1 January 1995
1989 Fatal error There is no data point for 1 January 1989 (since the data set starts on 1 July 1989).
2012 Fatal error There is no data point for 1 January 2012 (since the data set ends on 31 December 2011).

Several points should be noted regarding the use of this option:

When you choose to Enable Time Shifting of Time Series Data, GoldSim automatically wraps around to the start of the data set if the end of the data set is reached during a simulation. The manner in which this is done depends on the periodicity of the data:

The example file (TimeShifting.gsm) in the TimeSeries subfolder of the General Examples folder of your GoldSim directory (accessed by selecting File | Open Example... from the main menu) includes examples on the use of time shifting Time Series elements.