## Returns with Negative Prices

Once considered a mathematical impossibility, negative prices have become an established aspect of many financial markets. Negative prices arise in situations where investors determine that holding an asset entails more risk than the current value of the asset. For example, energy futures see negative prices because of costs associated with overproduction and limited storage capacity. In a different setting, central banks impose negative interest rates when national economies become deflationary, and the pricing of interest rate derivatives, traditionally based on positivity, have to be rethought (see Work with Negative Interest Rates Using Functions (Financial Instruments Toolbox)). A negative price encourages the buyer to take something from the seller, and the seller pays a fee for the service of divesting.

MathWorks^{®} Computational Finance products support several functions for converting between
price series *p*(*t*) and return series
*r*(*t*). Price positivity is not a requirement. The
returns computed from input negative prices can be unexpected, but they have mathematical
meaning that can help you to understand price movements.

### Negative Price Conversion

Financial Toolbox™ functions `ret2tick`

and `tick2ret`

support converting between price series
*p*(*t*) and return series
*r*(*t*).

For simple returns (default), the functions implement the formulas

$$\begin{array}{l}{r}_{s}(t)=\frac{{p}_{s}(t)}{{p}_{s}(t-1)}-1\\ {p}_{s}(t)={p}_{s}(t-1)({r}_{s}(t)+1).\end{array}$$

For continuous returns, the functions implement the formulas

$$\begin{array}{l}{r}_{c}(t)=\mathrm{log}\left(\frac{{p}_{c}(t)}{{p}_{c}(t-1)}\right)\\ {p}_{c}(t)={p}_{c}(t-1){e}^{{r}_{c}(t)}.\end{array}$$

The functions `price2ret`

(Econometrics Toolbox) and `ret2price`

(Econometrics Toolbox) implement the same formulas, but they divide by
Δ*t* in the return formulas and they multiply by Δ*t* in
the price formulas. A positive factor of Δ*t* (enforced by required
monotonic observation times) does not affect the behavior of the functions. Econometrics Toolbox™ calls simple returns *periodic*, and
continuous returns are the default. Otherwise, the functionality between the set of
functions is identical. This example concentrates on the Financial Toolbox functions.

In the simple return formula,
*r _{s}*(

*t*) is the

*percentage change*(

*PC*) in

*p*(

_{s}*t*− 1) over the interval [

*t*− 1,

*t*]

$$\begin{array}{l}PC=\frac{{p}_{s}(t)}{{p}_{s}(t-1)}-1\\ {p}_{s}(t)={p}_{s}(t-1)+PC\cdot {p}_{s}(t-1).\end{array}$$

For positive prices, the range of *PC* is (−1,∞), that is, anything
from a 100% loss (*p _{s}*:

*p*(

_{s}*t*− 1) → 0) to unlimited gain. The recursion in the second equation gives the subsequent prices;

*p*(

_{s}*t*) is computed from

*p*(

_{s}*t*− 1) by adding a percentage of

*p*(

_{s}*t*− 1).

Furthermore, you can aggregate simple returns through time using the formula

$$\frac{{p}_{s}(T)}{{p}_{s}(1)}-1={\displaystyle \prod _{t=2}^{T}\left({r}_{s}(t)+1\right)}-1,$$

where the left-hand side represents the simple return over the entire interval
[0,*T*].

Continuous returns add 1 to *PC* to move the range to (0,∞), the domain
of the real logarithm. Continuous returns have the time aggregation property

$$\mathrm{log}\left(\frac{{p}_{c}(T)}{{p}_{c}(1)}-1\right)=\mathrm{log}\left({\displaystyle \prod _{t=2}^{T}\left(\frac{{p}_{c}(t)}{{p}_{c}(t-1)}\right)}\right)={\displaystyle \sum _{t=2}^{T}\mathrm{log}\left(\frac{{p}_{c}(t)}{{p}_{c}(t-1)}\right)}={\displaystyle \sum _{t=2}^{T}{r}_{c}(t)}.$$

This transformation ensures additivity of compound returns.

If negative prices are allowed, the range of simple returns *PC*
expands to (−∞,∞), that is, anything from unlimited loss to unlimited gain. In the formula
for continuous returns, logarithms of negative numbers are unavoidable. The logarithm of a
negative number is not a mathematical problem because the complex logarithm (the MATLAB^{®} default) interprets negative numbers as complex numbers with phase angle
±*π*, so that, for example,

$$\begin{array}{l}-2=2{e}^{i\pi}\\ \mathrm{log}(-2)=2+i\pi \end{array}$$

If *x* < 0, log(*x*) = log(|*x*|)
± *i**π*. The log of a negative number has an imaginary
part of ±*π*. The log of 0 is undefined because the range of the
exponential
*e*^{iθ} is
positive. Therefore, zero prices (that is, free exchanges) are unsupported.

### Analysis of Negative Price Returns

To illustrate negative price inputs, consider the following price series and its simple returns.

p = [3; 1; -2; -1; 1]

p = 3 1 -2 -1 1

rs = tick2ret(p)

rs = -0.6667 -3.0000 -0.5000 -2.0000

This table summarizes the recursions.

The returns have the correct size (66%, 300%, 50%, 200%), but do they have the correct sign? If you interpret negative returns as losses, as with the positive price series, the signs seem wrong—the last two returns should be gains (that is, if you interpret less negative to be a gain). However, if you interpret the negative returns by the formula

$${p}_{s}(t)={p}_{s}(t-1)+PC\cdot {p}_{s}(t-1),$$

which requires the signs, the last two negative percentage changes multiply
*negative* prices
*p _{s}*(

*t*− 1), which produces

*positive*additions to

*p*(

_{s}*t*− 1). Briefly, a negative return on a negative price produces a positive price movement. The returns are correct.

The *round trip* produced by `ret2tick`

returns
the original price series.

ps = ret2tick(rs,StartPrice=3)

ps = 3 1 -2 -1 1

Also, the following computations shows that time aggregation holds.

p(5)/p(1) - 1

ans = -0.6667

prod(rs + 1) - 1

ans = -0.6667

For continuous returns, negative price ratios
*p _{c}*(

*t*)/

*p*(

_{c}*t*− 1) are interpreted as complex numbers with phase angles ±

*π*, and the complex logarithm is invoked.

```
rc = tick2ret(p,Method="continuous")
```

rc = -1.0986 + 0.0000i 0.6931 + 3.1416i -0.6931 + 0.0000i 0.0000 - 3.1416i

This table summarizes the recursions.

The real part shows the trend in the absolute price series. When
|*p _{c}*(

*t*− 1)| < |

*p*(

_{c}*t*)|, that is, when prices move away from zero,

*r*(

_{c}*t*) has a positive real part. When |

*p*(

_{c}*t*− 1)| > |

*p*(

_{c}*t*)|, that is, when prices move toward zero,

*r*(

_{c}*t*) has a negative real part. When |

*p*(

_{c}*t*− 1)| = |

*p*(

_{c}*t*)|, that is, when the absolute size of the prices is unchanged,

*r*(

_{c}*t*) has a zero real part. For positive price series, where the absolute series is the same as the series itself, the real part has its usual meaning.

The imaginary part shows changes of sign in the price series. When
*p _{c}*(

*t*− 1) > 0 and

*p*(

_{c}*t*) < 0, that is, when prices move from investments to divestments,

*r*(

_{c}*t*) has a positive imaginary part (+

*π*). When

*p*(

_{c}*t*− 1) < 0 and

*p*(

_{c}*t*) > 0, that is, when prices move from divestments to investments,

*r*(

_{c}*t*) has a negative imaginary part (−

*π*). When the sign of the prices is unchanged,

*r*(

_{c}*t*) has a zero imaginary part. For positive price series, changes of sign are irrelevant, and the imaginary part conveys no information (0).

### Visualization of Complex Returns

Complex continuous returns contain a lot of information. Visualizing the information can help you to interpret the complex returns. The following code plots the real and imaginary parts of the logarithm on either side of zero.

p = -5:0.01:5; hold on plot(p,real(log(p)),"b") plot(p,imag(log(p)),"r") xticks(-5:5) xlabel("Price (p)") ylabel("Ordinate") legend(["real(log(p))" "imag(log(p))"],AutoUpdate=false) grid minor

Due to the following identity

$$\begin{array}{l}{r}_{c}(t)=\mathrm{log}\left(\frac{{p}_{c}(t)}{{p}_{c}(t-1)}\right)\\ \text{=}\mathrm{log}({p}_{c}(t))-\mathrm{log}({p}_{c}(t-1))\\ \text{=}\underset{\text{blue}\text{\hspace{0.17em}}\text{curve}}{\underbrace{[\text{real}(\mathrm{log}({p}_{c}(t))-\text{real}(\mathrm{log}({p}_{c}(t-1)))]}}+\underset{\text{red}\text{\hspace{0.17em}}\text{curve}}{\underbrace{[\text{imag}(\mathrm{log}({p}_{c}(t)))-\text{imag}(\mathrm{log}({p}_{c}(t-1)))]}}\cdot i,\end{array}$$

you can read the real part of a continuous return as a difference in
ordinates on the blue graph, and you can read the imaginary part as a difference in
ordinates on the red graph. Absolute price movements toward zero result in a negative real
part and absolute price movements away from zero result in a positive real part. Likewise,
changes of sign result in a jump of ±*π* in the imaginary part, with the
sign change depending on the direction of the move.

For example, the plot below superimposes the real and imaginary parts of the logarithm
at prices *p* = −4 and *p* = 2, with lines
to help visualize their differences.

p = [-4; 2]; plot(p,real(log(p)),"bo-",MarkerFaceColor="b") plot(p,imag(log(p)),"ro-",MarkerFaceColor="r") hold off

If *p _{c}*(

*t*− 1) = −4 and

*p*(

_{c}*t*) = 2, the real part of log(

*p*(

_{c}*t*)) − log(

*p*(

_{c}*t*− 1)) is negative (line slopes down), corresponding to a decrease in absolute price. The imaginary part is 0 –

*π*= −

*π*, corresponding to a change of sign from negative to positive. If the direction of the price movement is reversed, so that

*p*(

_{c}*t*− 1) = 2 and

*p*(

_{c}*t*) = −4, the positive difference in the real part corresponds to an increase in absolute price, and the positive difference in the imaginary part corresponds to a change of sign from positive to negative.

If you convert the continuous returns
*r _{c}*(

*t*) = log(

*p*(

_{c}*t*)/

*p*(

_{c}*t*− 1) ) to simple returns

*r*= (

_{s}*p*(

_{s}*t*)/

*p*(

_{s}*t*− 1) − 1) by the following computation, the result is the same simple returns series as before.

rs = exp(rc) - 1

rs = -0.6667 + 0.0000i -3.0000 + 0.0000i -0.5000 + 0.0000i -2.0000 - 0.0000i

`pc = ret2tick(rc,Method="continuous",StartPrice=3)`

pc = 3.0000 + 0.0000i 1.0000 + 0.0000i -2.0000 + 0.0000i -1.0000 + 0.0000i 1.0000 + 0.0000i

### Conclusion

Complex continuous returns are a necessary intermediary when considering logarithms of
negative price ratios. `tick2ret`

computes a continuous complex
extension of the function on the positive real axis. The logarithm maintains the additivity
property, used when computing multiperiod returns.

Because of the extensible logarithm implemented in MATLAB, current implementations of Computational Finance tools that accept prices and returns behave logically with negative prices. The interpretation of complex-valued results can be unfamiliar at first, but as shown, the results are meaningful and explicable.

## See Also

## Related Topics

- Work with Negative Interest Rates Using Functions (Financial Instruments Toolbox)