[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Adaptive Loss and Profit Stops



PureBytes Links

Trading Reference Links

At 1:49 AM -0400 4/13/99, David Fenstemaker wrote:

>Has anyone been doing anything with
>adaptive stops?
>
<Snip>
>
>Has anyone had some success?
>

There may be a problem with terminology. The term "Stops" to me means the stops built into TradeStation. I will assume you mean what I would call "exits". All of my exits are "adaptive".

I program all entries and exits based upon price movement. There is the "expected" exit that occurs if the market moves as expected when I entered and I exit with a profit.

Then, there is the exit that occurs if the market does not do what I expected. I program this exit to occur at the point where it is clear that the premise of the original entry was faulty, when it becomes apparent that the market is not doing what I expected on the entry. 

This may not mean a loss. For example, if the entry expected the market to move up rapidly but the market stalls and does nothing, this would be a reason to get out, maybe without a loss. Often a failed signal is a good time to reverse.

I rarely use the stops available in TradeStation and if I do, they are set so that they are only hit if some disaster occurs that somehow was not caught by my exit code. I have found that using such simplistic stops almost always wrecks the performance of a system. I sometimes run an optimization using the money management stops in TradeStation and if this seems to improve the performance of the system, it means that my programmed exits are not working correctly.

One technique to accomplish this exit method is to create a "pseudo price" that is what you expect to occur. Then, take the difference between the actual price and this "pseudo price". If this "error signal" gets too big in the wrong direction, then I might exit. As a simple example, if the price is moving up and down in a 15 point channel with tops about 20 bars apart, after a long entry at the bottom of the channel, I would expect the price to move up at 1.5 points per bar. If it moved up much slower than this rate, I might decide to exit. Often, if the price breaks the expected "rhythm", it may be signalling a reverse.

I find that if the price doesn't do what I expect after an entry, then it is much better to get out rather than wait and hope that something good will happen by chance.

Another technique is to delay the actual entry until the price confirms what you expect to happen. An example is the attached code segment (that I recently posted to another list) that keeps a buy/sell order active for some number of bars until the price is moving in the right direction. This usually increases the percent profitablity but can increase slippage in some markets.

The comments in the code are for the buy side. The sell side is the mirror image. There are many variations of this idea.

Bob Fulks

------


if <buycondition> then begin   {When your system issues a buy signal    }
   BuyOK = TRUE;               {set the BuyOK flag to enable buy orders,}
   SelOK = FALSE;              {Turn off any existing SelOK flag,       }
   Count = 0;                  {Initialize a counter to count bars      }
                               {    since the buy signal                }
end;

if <selcondition> then begin
   BuyOK = FALSE;
   SelOK = TRUE;
   Count = 0;
end;

BuyPt = High + 1 point;        {Recalculate the buy stop point at each  }
SelPt = Low - 1 point;         { sucessive bar as price keeps dropping  }

if BuyOK then Buy next bar at BuyPt stop;   {if BuyOK true, issue the buy stop}
if SelOK then Sel next bar at SelPt stop;   {  for the next bar only          }

if Count < MaxCount then       {If the count is less than the max bars allowed}
   Count = Count + 1           {  increment the counter,                      }
else begin                     {  otherwise                                   }
   BuyOK = FALSE;              {  reset the buy flag to disable buy orders    }
   SelOK = FALSE;              {  until the next buy signal                   }
end;