Welcome to the Traders Laboratory Forums.
Coding Forum Collaborate, receive help, or discuss coding related issues.

Reply
Old 11-02-2007, 06:39 PM   #1

jjthetrader's Avatar

Join Date: Aug 2007
Location: Canada
Posts: 463
Ignore this user

Thanks: 217
Thanked 218 Times in 100 Posts



TradeStation Strategy Code Help

I'm running a TradeStation strategy to trade the S&P emini.
I use SetProfitTarget and SetStopLoss for my orders.

As soon as the profit target is reached, lets say 1 point, the strategy shows Profit Target on the screen at that point. But in real life the price needs to reach 1 tick higher to actually get me out with the profit target.

My question is if the price only gets to the profit target amount and not 1 tick higher to actually get me out, will my strategy know I'm still in, even though it's not, and set my Stop if it happens to reverse on me? Or will my strategy think I'm out and fail to set that stop?

I was running on auto all month and this is only occuring to me now but this scenario hasn't actually happened for me to know for sure.

Any help would be appreciated.
jjthetrader is offline  
Reply With Quote
Old 10-26-2010, 04:31 AM   #2

Join Date: Jul 2010
Posts: 58
Ignore this user

Thanks: 12
Thanked 15 Times in 13 Posts



Thumbs up Re: TradeStation Strategy Code Help

HI,
The SetProfitTarget (Amount of profit in dollars, at which point the position will be closed) and

SetStopLoss(Amount of loss, in dollars, at which point the position will be closed) will close the Position immediately. If you want your Positions to be closed 1 tick Higher , then You need to rewrite your exits.

Another Option is:-

You can add the dollar value of 1 tick with the Profit. I.e

SetProfitTarget(2000 + 12.5) where 12.5 is the 1 Tick value of The selected Stock.
This will exit at the Next Tick after reaching the Profit of 2000.

GoodLuck
EasyTrader_I
EasyTrader_I is offline  
Reply With Quote
Old 10-26-2010, 09:06 AM   #3

Join Date: May 2007
Location: Toronto
Posts: 247
Ignore this user

Thanks: 8
Thanked 143 Times in 53 Posts



Re: TradeStation Strategy Code Help

Quote:
Originally Posted by jjthetrader »
I'm running a TradeStation strategy to trade the S&P emini.
I use SetProfitTarget and SetStopLoss for my orders.

As soon as the profit target is reached, lets say 1 point, the strategy shows Profit Target on the screen at that point. But in real life the price needs to reach 1 tick higher to actually get me out with the profit target.

My question is if the price only gets to the profit target amount and not 1 tick higher to actually get me out, will my strategy know I'm still in, even though it's not, and set my Stop if it happens to reverse on me? Or will my strategy think I'm out and fail to set that stop?

I was running on auto all month and this is only occuring to me now but this scenario hasn't actually happened for me to know for sure.

Any help would be appreciated.

You have 2 options to make sure that your Strategy is in Sync with your real world position. Under the Strategy Properties Tab you can set the strategy to:

1. Replace a Strategy Limit order with a Market order XXX seconds after the strategy thinks the fill has occured

-or-

2. Set the Strategy to fill non-historical orders only when he TradeManager reports them as filled.

Either choice will make sure you are out when your target is hit.
bakrob99 is offline  
Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
TTM trend esignal code philloo Trading Indicators 9 04-16-2009 10:51 AM
{REQ} help with an exit strategy jjthetrader Coding Forum 4 09-22-2007 02:06 PM
Simple fib Strategy feb2865 Technical Analysis 1 09-19-2007 07:59 PM
What is your strategy when a trade goes against you jperl Technical Analysis 15 05-23-2007 12:41 AM
Floor Trader Pivot Code Help.... jmi88 Coding Forum 1 05-22-2007 11:13 PM

All times are GMT -4. The time now is 03:38 AM.
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
CS to VB integration by DeskLancer
©2006-2011 Traders Laboratory, All Rights Reserved.