2 Financial time-series and asset-pricing

  • If the sample data consists of the asset values observed over time (t=1, 2, 3,...,T) these are known as time–series or historical data

  • Univariate time–series is focused on a single asset, whereas multivariate time–series involves two or more assets observed at the same time points or intervals of time

  • Different assets in various markets, such as stock exchanges, foreign exchange markets, money markets, cryptocurrency markets, commodity markets (for istance oil) or precious metals markets (for istance gold), are typically valued by their prices

  • However, it is preferable to analyze returns rather than prices because returns provide a standardized measure of investment performance, allowing for easier comparison across different asset types, regardless of the price levels, scales or units

  • Returns are the percentage changes in the asset values from the current period t (such as a day, month, or year) to the previous period t1 (previous day, month, or year), reflecting the profits or losses (positive or negative returns) more clearly

Simple returns (also known as arithmetic returns) are calculated using the formula Rt=PtPt1Pt1           t=2,3,,T where Pt is current closing price and Pt1 is lagged closing price

Note: return for the first observation is always missing and it is often replaced with zero, assuming that the price has not changed compared to the period before t=1

Compound returns (also known as continuously compounded or log returns) are calculated using the formula rt=log(Pt)log(Pt1)first difference of the logs=Δlog(Pt)=log(PtPt1)           t=2,3,,T where log(·) is the natural log function

Note: it is costummary to use closing prices, instead of opening prices, as they reflect the asset value after a full day of trading and they are observed right before the most liquid and active part of the day when market closes, while opening prices are influenced by overnight news and pre–market activity

  • Replacing the first missing return with zero is practical for two reasons: (1) it keeps all observations in the sample, and (2) over a long time horizon returns have an approximately zero mean (sometimes returns are centered by demeaning process to ensure the mean is exactly zero)

  • Although returns Rt and rt reflect a relative change, they are not multiplied with 100 for easier computation later, but the final results are interpreted as percentages (%)

  • Unlike simple returns, log returns can be easily aggregated, i.e. by summing one–period log returns over k periods we get multi–period log return

rt(k)=rt+rt1+rt2++rtk+1=k1j=0rtj

  • For instance, summing daily returns from Monday to Friday yields the weekly return, summing daily returns from the first to the last day of the month gives the monthly return, summing monthly returns from January to December results in the annual return, etc.

  • By rewriting a simple return formula (2.1) as Rt=PtPt11, the connection between two types of returns is straightforward

rt=log(1+Rt)Rt=ert1

  • According to (2.4), nothing is lost by using log returns instead of simple returns, but the additivity of log returns is a crucial property, making log returns more convenient

  • In empirical studies weekly, daily or even intraday returns are most prevalent (instead of monthly, quarterly or annual returns) for several reasons:

  1. capturing market fluctuations and price dynamics more accurately when prices are observed in shorter time intervals (weeks, days, hours, minutes or seconds), as markets usually react very quickly to incoming events, published news or sentiment changes

  2. using more observations due to higher granularity

  3. developing short–term investment strategies

  4. improving algorithmic trading

  • The log returns can be computed in R in different ways and aggregated at different levels
TABLE 2.1: R packages and commands for computing log returns
Package Command Description
stats (base R) diff(log()) Generates first differences of the logs
quantmod dailyReturn() Computes daily log returns from prices
quantmod weeklyReturn() Computes weekly log returns from prices
quantmod quarterlyReturn() Computes quartely log returns from prices
quantmod monthlyReturn() Comptes monthly log returns from prices
quantmod annualReturn() computes annual log returns from prices
PerformanceAnalytics Return.calculate() Calculates simple or log returns
PerformanceAnalytics Return.centered() Calculates centered (demeaned) returns