# Positive Expectancy and Trading Your Edge - Metrics



## Nortorious (6 July 2016)

Hi All,

As I progress as a trader a couple of things have happened:

1) my trading strategy has become simpler and crystal clear
2) my record keeping and statistics/metrics have been expanding as tracking tools

I'm interested to know whether people have calculated their own expectancy of their trading strategies and what numbers they are hitting.

I had a change in my approach which has yielded vastly different results (in the positive) and since finding this edge and being able to trade it consistently, have seen a great change of favour.

Here's a table of some stats prior to having the "lightbulb" moment on my approach and current stats for my open trades (calculated on a per $1,000 basis). 




The open trades ratio sits at 5.91:1 (but obviously fluctuates based on daily values). 

As you can see, a massive difference to the previous ratio that existed and the wins to losses trade ratio has improved as well.

So why am I writing all this?

Basically I would like to know the ratios for your edge... What's your positive expectancy and how do you track it?

I'm planning to track my stats over time rather than running mechanical back tests but with a small sample size (at the moment) things look good.


----------



## skc (6 July 2016)

Nortorious said:


> Here's a table of some stats prior to having the "lightbulb" moment on my approach and current stats for my open trades (calculated on a per $1,000 basis).




I don't understand your trade calculated per $1,000 basis. Is every one of your trade the same size? For most traders each trade will have very different size depending on risks of the particular set up. I guess what I am saying is, if each trade size is different, normalising that to a "per $1,000 basis" will not give any data. 

What I would do is simply use average win and average loss. Or if you don't want to disclose the absolute amount, normalise the average win $100 and calculate the average loss (perhaps that's what you are doing already but it's unclear from what you posted).

Congrats on your progress towards more success.


----------



## Triathlete (7 July 2016)

Nortorious said:


> Hi All,
> 
> As I progress as a trader a couple of things have happened:
> 
> ...





I do not take that many trades as I  mainly  position trade when the opportunity arises, my stats below.

Trades..........................   28
Wins..........................      21
Loss..........................        2
Open..........................       5
Win / Loss...................  91.3%
Ave /Profit..................  19.9%
Ave Loss.......................14.2%
Ave day in trade.........   125


----------



## howardbandy (8 July 2016)

Greetings --

When analyzing performance such as expectation per trade, the correct procedure is to use percentage per trade.  Using a constant dollar amount for each trade makes it easy to see that metric.  If the system has applied any position sizing, including compounding, be careful to ignore the effect of position sizing -- because that metric is sequence dependent and the resulting analysis will be misleading because of the optimistic bias introduced.

Best,
Howard


----------



## Triathlete (8 July 2016)

howardbandy said:


> Greetings --
> 
> When analyzing performance such as expectation per trade, the correct procedure is to use percentage per trade.  Using a constant dollar amount for each trade makes it easy to see that metric.  If the system has applied any position sizing, including compounding, be careful to ignore the effect of position sizing -- because that metric is sequence dependent and the resulting analysis will be misleading because of the optimistic bias introduced.
> 
> ...




Thanks Howard, I use a spread sheet to input my trades so I have pulled out the percentages from that. If we use a constant position size of 10K per trade without any leverage I am coming out with a net profit of 17% on money outlaid without adding dividends.

If we look at the $ amount across the 21 win trades we have an average $1853 per win and for the  losses is $1415 per loss with average time in trade 125 days. Is this the way to explain it ??? if not can you explain further thanks..


----------



## Nortorious (8 July 2016)

skc said:


> I don't understand your trade calculated per $1,000 basis. Is every one of your trade the same size? For most traders each trade will have very different size depending on risks of the particular set up. I guess what I am saying is, if each trade size is different, normalising that to a "per $1,000 basis" will not give any data.
> 
> What I would do is simply use average win and average loss. Or if you don't want to disclose the absolute amount, normalise the average win $100 and calculate the average loss (perhaps that's what you are doing already but it's unclear from what you posted).
> 
> Congrats on your progress towards more success.




Hi SKC,

So what I have done to calculate on a $1,000 per trade basis is to find a common denominator to be able to analyse performance per trade. My position sizes vary based on the risk involved when the trade is first entered. Some stocks where the initial risk is low (say a 5% risk on the position) I open larger trades as the overall portfolio risk can be capped at 3%. For trades where the initial risk is 30% on the trade, a smaller position is taken, again to limit portfolio risk to 3% max.

As you said, I could normalise against a $100 value as that would be the same process.

Thanks for the input and asking the question to find the method of the madness.


----------



## Trendnomics (9 July 2016)

Great thread - related to my pet hate and everyone's stumbling block.

Just comparing expectancy values for different systems/strategies, is like the age old analogy of apples vs. pears. "Expectancy" (per trade) is only one dimension of a profitable system, the other dimension, is "Number-of-Trades" (per time period):

_System Expected Profit = Expectancy x Number-of-Trades_

Expectancy should be adjusted by the number of trade positions for a system/strategy:

_Expectancy = [(Average_win x %_win) - (Average_loss x %_loss)]/(Trade_positions)_

The metrics for my Trend-Following System are as follows:

Average_win = 30.77%
Average_loss = -12.13%

%_win = 47.3%
%_loss = 52.7%

Trade_positions = 16

Expectancy = 1.31% /trade
Number-of-Trades = 37 trades/year

*System Expected Profit = 48.47% / year*

Note that expectancy values, are based on normal-distributed outcomes - approximate reflection of real trading results (quite a bit off for trend-following).


----------



## howardbandy (9 July 2016)

Another useful metric is relative account growth -- TWR (Terminal Wealth Relative) in Ralph Vince's terminology.  An account that grows from $120,000 to $180,000 in a period has TWR of 1.5

If n is the number of trades in a period, and g is the geometric average return per trade (the geometric expectation), then:

TWR = g ^ n

^ is exponentiation.
TWR is the geometric expectation raised to the power of the number of trades.

You want n to be a big number.  Trade often.

Over a given period of time, trading often usually implies shorter holding periods, which is advantageous in helping control risk. 

Best,
Howard


----------



## lftrader (12 July 2016)

howardbandy said:


> Greetings --
> 
> When analyzing performance such as expectation per trade, the correct procedure is to use percentage per trade.  Using a constant dollar amount for each trade makes it easy to see that metric.  If the system has applied any position sizing, including compounding, be careful to ignore the effect of position sizing -- because that metric is sequence dependent and the resulting analysis will be misleading because of the optimistic bias introduced.
> 
> ...




Hi Howard,

Wouldn't constant dollar amount underestimate losses due to a market crash when system is fully invested?


----------



## howardbandy (12 July 2016)

lftrader said:


> Hi Howard,
> 
> Wouldn't constant dollar amount underestimate losses due to a market crash when system is fully invested?




Fully invested means the fraction of the trading account used for each trade is 1.00.  That method of position sizing is called "fixed fraction."  Fixed fraction is a reasonable position sizing technique, and the one I recommend.  We want the largest positions that can be taken with the funds available in order to have the highest account equity after some number of trades -- provided the drawdown during that period does not exceed our personal risk tolerance.  The position size that does that is the specific fixed fraction with a value of "safe-f."  

The value of safe-f is computed by beginning with a set of trades that are the best estimate of future performance.  The values of that set are the percentage gained rather than the number of dollars gained.  To work with geometric growth, where TWR = g ^ n, a trade that gains 1 percent has a g of 1.01 and a trade that loses 2% has a g of 0.98.  For a constant fraction over the test period, the final account value after a given number of trades does not depend on the sequence of those trades, but the drawdown does depend on sequence.  

The calculation of safe-f forms, then examines, the distribution of possible drawdowns from the given set of trades and sets safe-f to the largest value that holds drawdown to an acceptable level.     

It may turn out that safe-f is 1.00 for the system you are working with.  But most systems have more risk than can be tolerated and safe-f is lower than 1.00.

Given a value for safe-f, we can go back and compute the equity in dollars.  But be careful to not expect the one single equity curve that resulted from the backtesting to be typical.  It is not.  The trade sequence and equity curve resulting from a backtest is almost always (99% or higher) overly optimistic.  Rather, look at the distribution of possible equity curves where trades come from the best estimate set but occur in different order.

I hope this helps.  The point is -- analysis of risk is more complex than just looking at the report of the backtest.

Best,
Howard


----------



## lftrader (21 July 2016)

howardbandy said:


> The value of safe-f is computed by beginning with a set of trades that are the best estimate of future performance.




Thanks Howard. Does best estimate mean a "representative sample"? Does that assume normal distribution of returns? In his website Mike Harris refers to non-stationarity and that the expected return is a random variable due to that. Do you think this means that stops are needed to avoid ruin and how do stops affect "safe-f' calculations? This has always been a confusing subject for me.


----------



## howardbandy (21 July 2016)

Hi LF --

Best estimate is the set of trades that are the best estimate of future performance of the system being evaluated.  If there is a history of live trades, that is probably the very best.  In decreasing value are paper trades from a system that has been through development and validation, but is not yet trading.  The out-of-sample results from the walk forward validation would be an example. 

Best estimate uses a sliding window of recent trades in order to measure the degree of synchronization between the model and the data.  The length of the window is a system "hypervariable", just as is the length of the in-sample period.  There is no way to tell its length without some experimentation.

The risk assessment process works with any set of trades, but the process does not "understand."  If the trader uses a set of trades that are not representative of the future, the process will still go through the calculations, but the results will be misleading.  Using in-sample trades would be an example.  In-sample results always overestimate profit and underestimate risk.

Stationarity refers to a distribution.  In this case, we are forecasting the risk and profit of future trades.  We need the distribution of trades in the future to be similar to the distribution that resulted from the validation that created the best estimate set.  Watch my YouTube video for more about stationarity:
https://www.youtube.com/watch?v=iBhrZKErJ6A&feature=youtu.be

Whether the distribution is "normal" or not makes no difference.  First, the distribution will not be normal.  Second, the risk analysis process forms the distribution from whatever trades are presented to it and goes from there.  The distribution is what it is.  There is no need to put a name on it, no value from putting a name on it, no value from having it be one of the standard distributions, and a very large mistake by assuming it is a particular distribution that it is not.

If a system produces trades that are similar and with these characteristics -- accurate trades, small gains, small losses, no very large losses -- that will have a very different distribution from a 1980s Turtle where the accuracy is poor, there are many small to medium losses and a few large gains.  Neither is normal.  Either can be used.  What comes out of the analysis is an estimate of the "risk-normalized" profit potential.  Best estimate sets that have a small number of trades, a large percentage of losing trades, and / or large individual losing trades, are at risk of larger drawdowns in the future.  Since drawdown is the limitation of most traders, position size must be reduced to limit drawdowns to an acceptable level, which in turn limits future profits.  This video discussing risk might be helpful:
https://www.youtube.com/watch?v=Vw7mseQ_Tmc&feature=youtu.be 

Stops are components of the trading system.  Whatever trades result from the trading system are what they are.  An exit caused by a stop or an exit caused by a rule applied to an indicator are treated as the same.  By the time the risk analysis procedure sees the trades, the cause of the entry or exit is not material.  

Position size should not be a component of the trading system.  Position size belongs in the trading management system.  If position size is included with the trading rules, there are two major problems:
1.  The trading system has no way of knowing whether the model and the data are well synchronized or not.  It cannot set position size accurately without assuming that position size will be static -- that is, without treating the trading system as being stationary.  And trading systems are not stationary.
2.  The input to the trading management system is a series of trades.  The output from the trading management system is position size -- safe-f -- which is CAR25 of the risk-normalized estimate of future performance.  It is the metric of system health and the metric by which alternative uses of funds can be compared.  If position size is not available to the trading manager, he or she has no way of determining system health and no way of adjusting position size to take advantage of good sync or to avoid serious drawdown.

Thanks for listening,
Best, Howard


----------



## Roller_1 (21 July 2016)

howardbandy said:


> Hi LF --
> 
> Best estimate is the set of trades that are the best estimate of future performance of the system being evaluated.  If there is a history of live trades, that is probably the very best.  In decreasing value are paper trades from a system that has been through development and validation, but is not yet trading.  The out-of-sample results from the walk forward validation would be an example.
> 
> ...




Howard,

When selecting a set of live or out of sample trades isn’t it dangerous or inaccurate to assume that the selected set of trades will be the “best estimate of future performance”? 

Selecting a small sample of trades could return a basically random result, a system is designed to have a positive return over the longer term (a number of years not weeks or months). So even a years worth of out of sample trades might not be a good estimate of future performance.


----------



## howardbandy (22 July 2016)

Hi Roller --

We are interested in the distribution of signals and resulting trades.  For a given trading system -- model plus data -- there is a population (or universe).  We can see only a small portion of the population -- a sample.  As with most modeling, simulation, and prediction activities, we are interested in making predictions about the future signals and trades based on the sample we are able to observe.  There must be some sample.  We want that sample to be the best possible estimate of the population.  

To be perfectly clear -----
The purpose of system development is to learn as much as possible about the population of signals and trades associated with a trading system.  

One (OK, two) of the questions I ask of myself and of every class I teach is:
What would I like to know about tomorrow?  What would I do if I knew that?

The most I can ever know (without insider information) is a reasonably accurate estimate of the distribution of signals that precede profitable trades.  

One of the tenets of technical analysis is that the future must resemble the past.  The statistical term for that condition is stationarity.  

Our development consists of (at least) these two tasks --
1.  Determine the length of time the system is stationary.
2.  Establish the best estimate of the population that we can -- that is, make the best estimate of the distribution of signals and trades over the period being analyzed that we can. 

In the end, the goal is to have a trading system that provides reward adequate to compensate for the risk, and in which the trader has confidence.  

Forming the best estimate set is definitely not random.  If available, use real trades.  Or paper trades from a system that has gone through validation.  Or the trades that result from the validation phase.  (Do not use the in-sample results, they will be very misleading.) 

If the best estimate sample set is not formed from the most representative data available, then how would it be formed?  What would be used?  

Best regards,
Howard


----------



## lftrader (25 July 2016)

Howard, Thanks for detailed answers.

I have a question about this statement you made above:

<Position size should not be a component of the trading system. Position size belongs in the trading management system.>

My question is: when we collect a sample to determine position sizing what initial position sizing do we use? 

Because that has an effect on the type of returns of the system. 

I have trouble with separation of trading system from trading management. Most definitions of trading system I have seen include the following more or less:

1. Entry rules
2. Exit rules
3. Risk and money management

If I assume I have validated a system, do I use the trades from out-of-sample on a per contract basis to determine the sample for position size calculation? 

Thanks


----------



## howardbandy (26 July 2016)

Hi LF --

The information needed to do the risk assessment begins with percentage gain per trade (for systems that use impulse signals) or percentage gain per day (for systems that use mark-to-market daily accounting and state signals).  Since there is no position sizing in the trading system, and there is at most one position on at a time, any combination of initial equity and position size  that ensures there will be enough money to take all trades will work.

I use:
initialequity = 100000
dollarsize = 10000

The results I pass on to the risk analysis procedure is the percentage gained from each trade.  All trades begin with as many shares as $10,000 will buy.  At the exit to each trade that trade will have gained or lost some dollar amount -- say a gain of $400.  The percentage gained is 400/10000 or 0.4%.  

The initial equity and dollar size do not matter, providing there is always enough money to take a 10000 position.

------------------

I understand that many of the trading system recommendations include position size.  In my opinion, that is poor advice.  

When position size is included in with the rules that generate trading signals, there is an assumption that that position size can be determined in advance.  A system is a combination of a model (rules) and data.  The system identifies the patterns that precede profitable trades only as long as the model and data remain well synchronized.  When the data changes, the model cannot adjust enough, and trading performance deteriorates.  If the position size calculation is in the trading management portion, the trader can recognize that the position size should be reduced. 

The videos I have posted on YouTube might help:
http://www.blueowlpress.com/video-presentations

Best regards,
Howard


----------



## lftrader (31 July 2016)

howardbandy said:


> I use:
> initialequity = 100000
> dollarsize = 10000
> 
> ...




Hello Howard, thanks for the explanation but I am skeptical about the method you propose.

Let us consider a security that closes some Monday at 100 and then the next Tuesday at 101. 

The return is found below

(101/100) -1 = 0.01  = 1%

If we invest passively in the security on Monday, we will need to invest all of our equity to realize the same return. If, as you say, our initial equity is 100000 but we invest only 10000, certainly our return on 10000 is 1% but on 100000 it is 0.1%.

What I am saying is that security returns assume fully reinvested equity, some people call it geometric growth.

If you take the returns of a trading systems with constant dollar size as you suggested, returns between actual security and system will be in mismatch.

Thanks


----------



## howardbandy (2 August 2016)

Hi LF --

The purpose of having all trades based on the same amount is to focus on the gain per trade, not letting sequence-dependent results bias our analysis.  That set of equal-sized trades is used in a separate procedure to determine the position size that gives the highest compound annual rate of return while keeping drawdown within the tolerance of the trader.  

It might be helpful to read the free chapters of my "Mean Reversion Trading Systems" book.  In particular, look at page 39 in Chapter 2.  There are two systems.  One, on the left, is what we normally think of when discussing a trading system.  It takes price and volume as input and produces signals and trades as output.  There is no position sizing in that model.  Two, on the right, is the trading management system.  It takes trades as input and produces position size as output.

If position size is included in the trading system (left side), then there is no "knob to turn" to manage trading (right side).  No metric to suggest how to increase position size in response to good performance or, importantly, how to decrease position size in response to poor performance.

http://www.blueowlpress.com/123-2/mean-reversion-trading-systems

Best,
Howard


----------



## lftrader (11 August 2016)

howardbandy said:


> If position size is included in the trading system (left side), then there is no "knob to turn" to manage trading (right side).  No metric to suggest how to increase position size in response to good performance or, importantly, how to decrease position size in response to poor performance.
> 
> Howard




I don't know Howard, not convinced. If performance is poor position size is automatically adjusted because equity is lower. If performance if good, position size increases due to extra equity. Trey say to keep it simple. I find unnecessary extra complexity in other methods. I may be wrong but until I see some formal proof I cannot decide best approach to this.


----------



## howardbandy (12 August 2016)

lftrader said:


> I don't know Howard, not convinced. If performance is poor position size is automatically adjusted because equity is lower. If performance if good, position size increases due to extra equity. Trey say to keep it simple. I find unnecessary extra complexity in other methods. I may be wrong but until I see some formal proof I cannot decide best approach to this.




Greetings --

"Trey say to keep it simple."   Who is Trey?  Said what?  Said where?

I'll agree if we can amend the statement to be:  Keep it simple, but not simplistic.

Formal proof?  For what part of trading does formal proof of anything even exist?  Every formal proof I have read begins with assumptions that are unrealistic.  

Some examples:  
Efficient market -- no!  
Stationary distributions -- definitely not! 
Risk is immaterial -- really? 
Decision trees are the only models -- says someone who has not heard about support vectors or random forests.
Immunity to the curse of dimensionality -- don't we wish!  
Low variance in in-sample results equates to high accuracy in out-of-sample results -- novice error number one!  etc.  

All are good for publishing papers in support of applications for academic tenure.  None are good for or even applicable to trading.  

You are already deciding.  You have chosen what you feel is the "best approach" by doing whatever you are already doing.  My point is that hearing about a different -- perhaps better, but that depends in part of your subjective preferences -- approach might be valuable.  

The goal is confidence.  Confidence that the signals generated by the system precede trades that are profitable at acceptable risk.  No one can give you the confidence -- you need to develop that yourself.  The best I can do is point you in the right direction.  And provide some analysis tools that give quantifiable metrics to the statement of confidence.  

The discussion, examples, and ready-to-run computer code listed in the Quantitative Technical Analysis book are as close to proof as will be found in a practical book. 

Is there disagreement with the concept of reducing exposure when performance is poor and increasing exposure when performance is good?  That is the trading implementation of the broad concept of anti-Martingale position sizing and betting.  Any of a dozen good books will give more math than most of us want to show that Martingale guarantees bankruptcy -- that anti-Martingale is preferred.  For a worked out example, begin on page 93 of my "Modeling Trading System Performance" book.

Dynamic position sizing does more than reduce position size by the proportion the equity has already lost.  Just reducing position size to keep it in proportion to equity remaining is not "position sizing."  If the system has broken, for whatever reason, the trader will lose the entire account. 

Rather, dynamic position sizing estimates the risk of a drawdown greater than the tolerance that the trader him- or herself has defined and sets position size so the probability of that drawdown is low -- where the trader has defined what low means.  If the system is broken, dynamic position sizing sets the value of safe-f -- the safe position size given the recent trades and the traders statement of risk tolerance -- to zero.  It takes the system offline before all equity is lost.  In most cases, excepting black swan events, before the traders risk tolerance has been exceeded.

Now, what is the statement you want proof of?  And what would be convincing proof?    

Thanks for listening,
Howard


----------



## lftrader (11 September 2016)

"Trey say to keep it simple." Who is Trey?

Ops, typing in the dark. It's they. sorry.

All successful traders I know keep it simple. Some book authors attempt to fill pages and pages with complicated position size methods for which there is no proof they work. Fixed fractional is recommended by many successful traders. Success is related to simplicity. 

"Is there disagreement with the concept of reducing exposure when performance is poor and increasing exposure when performance is good? "

Yes because at the time of reduction performance may get better. The claim you make is vacuous in the absence of formal proof. One can present charts where it works and someone else charts where it fails.  Best.


----------



## howardbandy (12 September 2016)

Hi LF --

Please re-read "Foundations of Trading."  

Best regards,
Howard


----------



## Gringotts Bank (12 September 2016)

lftrader said:


> "Trey say to keep it simple." Who is Trey?
> 
> Ops, typing in the dark. It's they. sorry.
> 
> ...




You can paste your P/L per trade into excel to check this.  If losing trades tend to follow losing trades (as is the case with many systems), then reducing size after a losing trade makes sense.  A simple formula might halve the P/L for the next trade if the previous one was a loser.  Then chart it to check it against the fixed position size.  Howard's very meticulous with his work - you can trust him, imo.  His books can be hard to read if you don't have a stats/maths/programming background (like me, I don't), but the info is all there.


----------

