f u t u r e ra
Docs: time series / Toc / Introduction

SUMMARY

-Introduction to time series

An overview of the structure of a time serie.

What is a time serie

A time series is a sequence of data points that occur in successive order over some period of time. ... In investing, a time series tracks the movement of the chosen data points, such as a security's price, over a specified period of time with data points recorded at regular intervals.

A time serie:
- can be stationary;
- can have seasonality;
- can be autocorrelated;
- can have a trend;
- have noise

Stationary

A time series is said to be stationary if its statistical properties do not change over time. In other words, it has constant mean and variance, and covariance is independent of time. This means that no matter at what point in time you observe the series, the properties are the same.

A flat looking series, without trend, constant variance over time, a constant autocorrelation structure over time and no periodic fluctuations (seasonality).

There are two main types of stationarity:
- Strict Stationarity
- Weak Stationarity (or Wide-sense stationarity): This is a less strict condition where only the mean and variance need to be constant over time, and the covariance between two time periods depends only on the lag between the two time periods and not the actual time at which the covariance is computed.

Ways to check a time series for stationary
- Visual Inspection
- Summary Statistics
- Statistical Tests

Example stationary
Seasonality

Seasonality refers to periodic fluctuations. Recognizing recurring patterns that occur at regular intervals (e.g., monthly, yearly).

- Days of the week: Sales might be higher on weekends or specific weekdays.
- Months of the year: Retail sales are typically higher during the holiday season.
- Time of day: Traffic congestion is often worse during rush hour.
- Years: Economic cycles may have recurring peaks and troughs.

Example seasonality
Autocorrelation

Autocorrelation in time series analysis refers to the correlation between values of a time series at different points in time. In other words, it measures how closely related a data point is to its previous values.

Positive autocorrelation: When a data point is positively correlated with its previous values, it means that high values tend to follow high values, and low values tend to follow low values. For example, stock prices might exhibit positive autocorrelation, as a rise in price today might be followed by a rise tomorrow.

Example autocorrelation
Trend

A trend in time series analysis is a long-term pattern or direction in the data. It's a general upward or downward movement that persists over a significant period.

Characteristics:
- Persistence: Trends tend to continue for a sustained period, rather than being short-term fluctuations.
- Direction: Trends can be either upward (increasing) or downward (decreasing).
- Magnitude: Trends can vary in their steepness or rate of change.

Identifying trends:
- Visual inspection: Plotting the time series data and looking for a clear upward or downward slope.
- Statistical methods: Using techniques like linear regression to fit a trend line to the data.
- Smoothing techniques: Applying methods like moving averages or exponential smoothing to reduce noise and highlight the underlying trend.

Methods:
- Linear trends: A straight line relationship between the time variable and the data.
- Non-linear trends: A curved relationship, such as exponential or logarithmic trends.
- Cyclical trends: Patterns that repeat over a period of time, but may not be strictly periodic.

Noise

Noise in time series analysis refers to random fluctuations or irregularities in the data that don't follow any discernible pattern. It can be caused by various factors, such as:

Measurement errors: Inaccuracies in the measurement process.
Random events: Unexpected occurrences that disrupt the normal pattern of the data.
Unmodeled factors: Factors that are not explicitly accounted for in the model.

Characteristics of noise:
Randomness: Noise is unpredictable and doesn't follow any specific pattern.
Short-term: Noise often has a short-term impact on the data, rather than a long-term trend.
High frequency: Noise tends to have a higher frequency than underlying trends or seasonal patterns.

Impact of noise:
Reduced accuracy: Noise can make it difficult to accurately identify trends, seasonality, and other patterns in the data.
Increased uncertainty: Noise can increase the uncertainty in forecasts and predictions.
Reduced signal-to-noise ratio: The signal-to-noise ratio is a measure of the strength of the signal (the underlying pattern) relative to the noise. High levels of noise can reduce the signal-to-noise ratio.

Dealing with noise:
Smoothing techniques: Applying techniques like moving averages or exponential smoothing to reduce the impact of noise.
Filtering: Using filters to remove high-frequency components of the data, which are often associated with noise.
Robust methods: Employing statistical methods that are less sensitive to outliers and noise.

By understanding and addressing noise, analysts can improve the accuracy and reliability of their time series analysis.

BETA