Skip to content
All library documents

Comparing Prediction Loss with Portfolio-Value Optimization

Article Quant Q&A · Author: Tony Tieger

Summary

The document asks whether a time-series model that chooses a fully invested long or short position could be trained by maximizing simulated terminal portfolio value instead of minimizing squared prediction error. It proposes simulating daily positions from linear regression predictions, compounding the resulting returns, and potentially including trading costs. It also considers transforming returns to reduce the effect of unusually large observations that may be difficult to predict from the available features.

No answer, experiment, or performance comparison is provided. The question itself highlights possible drawbacks, including greater sensitivity to overfitting and the loss of a straightforward gradient-descent objective. The proposed return transformation changes the simulated payoff measure, so it would need careful justification; the document does not establish that it controls overfitting or improves out-of-sample results. Execution costs, position risk, and evaluation on unseen data are mentioned or implied as relevant but are not analyzed.

Key ideas

  • The document proposes maximizing simulated terminal portfolio value as an alternative training objective for directional predictions.
  • The example strategy switches between fully invested long and short positions based on predicted returns.
  • A nonlinear return transform is proposed to reduce the influence of large observations.
  • The document raises overfitting and optimization concerns but provides no answer or empirical evidence.
  • Trading costs and out-of-sample performance would matter when assessing the proposal.

Tags

Full text
# In Linear Regression for time series stock prediction, instead of cost function, use final portfolio value?


# In Linear Regression for time series stock prediction, instead of cost function, use final portfolio value?












In Linear Regression for time series stock prediction, instead of using the cost function and minimizing the cost function, why can't we use the final portfolio value? Assume we are doing a time series prediction, where each day we are either long or short a particular stock or index, and never in cash (this could be a logistic regression but let's use linear regression).

For example, start with $10k, and run regression using 5 years of data. We are doing a linear regression on daily returns (or we could cube root the returns to transform them to reduce the affect of crashes, etc, on the data, that are caused by factors that are probably not in the features used as predictors).

In any case, we minimize the cost of each day's prediction. For example, assume the prediction predicts +0.030, then we would be long, if it predicts -0.001 (slightly negative), then we should be short, always the entire portfolio value. We minimize the cost function which is just the error, (H(x)-y)^2.

Instead, we can take each day's prediction, and the actual outcome had we followed that prediction, and starting with say, $10k, simulate what the final portfolio value would be (we can add slippage for commission, etc, but I don't think that would matter here). Then, instead of minimizing the cost function, we maximize the final portfolio value.

What are the pros/cons of doing it the second way? I know we wouldn't be able to use gradient descent, for one thing. Also it is probably more susceptible to overfitting, but the transform can/should help with that, right? By transform, I mean say system predicted "0.040" which is a buy or long. The actual "cost" is that by being long, we gained 9.0%, which is out of the ordinary (some news came out, earnings, etc, that system doesn't predict or can't predict, and we don't want to "over-fit" this). By doing a cube root transform, we use 0.09^(1/3)=0.448. We can divide by 100 to avoid too high of returns, and assume today's return was 0.448% instead of 9%. We would tabulate final portfolio value using the transformed returns from our predictions, instead of actual returns. This has the affect of making outliers (like the 9% gain in one day) have a lower affect on the "cost".

So, what are the reasons we don't use final portfolio value maximization as the "cost function", instead of the normal 12m∑i=1m(hθ(X(i))−Y(i))2?

Shown in full with attribution under the source's licence. Licence: CC BY-SA 4.0 (Stack Exchange)

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.