Hi All,
I am a TradeStation Beginner and attempting to code a money management strategy that I can't seem to get working.
the code is as follows:
if(marketPosition = 1) then
begin
longProtStop = entryprice - (moneyManStop/PointValue/PriceScale);
longProfitStop = entryprice + (takeProfitStop/PointValue/PriceScale);
osCount = 0;
end;
and correspondingly:
if (marketPosition = 1) then
begin
ExitLong ("longLoss")next bar at longProtStop on a stop;
ExitLong ("longProfit") next bar at longProfitStop on a limit;
my problem is that the takeProfitStop and moneyManStop values that are returned when I test the signal are incorrect. With an input of $5 as a money management stop, I can incur a loss of nearly $3 per share on 1000 shares, which is obviously incorrect. My question then, is this: is my formula for determining money management targets incorrect, or are my settings for PointValue and PriceScale somehow incorrect? If so, can these be changed, or are they determined automatically be the program?
As always, any help would be greatly appreciated!
-Ben
I am a TradeStation Beginner and attempting to code a money management strategy that I can't seem to get working.
the code is as follows:
if(marketPosition = 1) then
begin
longProtStop = entryprice - (moneyManStop/PointValue/PriceScale);
longProfitStop = entryprice + (takeProfitStop/PointValue/PriceScale);
osCount = 0;
end;
and correspondingly:
if (marketPosition = 1) then
begin
ExitLong ("longLoss")next bar at longProtStop on a stop;
ExitLong ("longProfit") next bar at longProfitStop on a limit;
my problem is that the takeProfitStop and moneyManStop values that are returned when I test the signal are incorrect. With an input of $5 as a money management stop, I can incur a loss of nearly $3 per share on 1000 shares, which is obviously incorrect. My question then, is this: is my formula for determining money management targets incorrect, or are my settings for PointValue and PriceScale somehow incorrect? If so, can these be changed, or are they determined automatically be the program?
As always, any help would be greatly appreciated!
-Ben