modified profit target - TradeStation | futures io social day trading
futures io futures trading


modified profit target
Updated: Views / Replies:728 / 6
Created: by maggtrading Attachments:1

Welcome to futures io.

(If you already have an account, login at the top of the page)

futures io is the largest futures trading community on the planet, with over 90,000 members. At futures io, our goal has always been and always will be to create a friendly, positive, forward-thinking community where members can openly share and discuss everything the world of trading has to offer. The community is one of the friendliest you will find on any subject, with members going out of their way to help others. Some of the primary differences between futures io and other trading sites revolve around the standards of our community. Those standards include a code of conduct for our members, as well as extremely high standards that govern which partners we do business with, and which products or services we recommend to our members.

At futures io, our focus is on quality education. No hype, gimmicks, or secret sauce. The truth is: trading is hard. To succeed, you need to surround yourself with the right support system, educational content, and trading mentors – all of which you can find on futures io, utilizing our social trading environment.

With futures io, you can find honest trading reviews on brokers, trading rooms, indicator packages, trading strategies, and much more. Our trading review process is highly moderated to ensure that only genuine users are allowed, so you don’t need to worry about fake reviews.

We are fundamentally different than most other trading sites:
  • We are here to help. Just let us know what you need.
  • We work extremely hard to keep things positive in our community.
  • We do not tolerate rude behavior, trolling, or vendors advertising in posts.
  • We firmly believe in and encourage sharing. The holy grail is within you, we can help you find it.
  • We expect our members to participate and become a part of the community. Help yourself by helping others.

You'll need to register in order to view the content of the threads and start contributing to our community.  It's free and simple.

-- Big Mike, Site Administrator

Reply
 
Thread Tools Search this Thread
 

modified profit target

  #1 (permalink)
Trading Apprentice
méxico df, méxico
 
Futures Experience: Advanced
Platform: ninjatrader, tradestation
Broker/Data: demo so far
Favorite Futures: stocks, fdax, fdxm, fesx, rb, ho, ng, cl, tf, nq, bp, ec, jy
 
Posts: 46 since Mar 2013
Thanks: 115 given, 21 received

modified profit target

happy year and happy holidays to everyone,


i'm trying to code / find a modified version of a profit target.


the profit target automated strategy included in tradestation does fine, but it always closes the whole position.


i would like to be able to drop half my position at say, position +1.5, and keep the other half to be closed by the standard profit target, stop loss strategies.


i'm trying to code it, but can't even get tradestation to return the entry price, much less set the exit properly.


any help would be appreciated, thanks.

Reply With Quote
 
  #2 (permalink)
Market Wizard
Hamburg Germany
 
Futures Experience: Advanced
Platform: Multicharts, Tradestation, Multicharts.NET, NinjaTrader, MetaTrader
Broker/Data: DTN IQ
Favorite Futures: ES
 
Posts: 1,533 since Apr 2013
Thanks: 231 given, 854 received
Forum Reputation: Legendary

maggtrading,

I would do something like this:

- Open two positions and each with half of the total shares/contracts
- send a limit exit order for the target for the first leg of your entry
- either send a limit exit order for the second target or use the build in Profit Target

You can get the entry price with the reserved word EntryPrice(Num).

Where Num is a numeric expression representing the number of positions ago (up to a maximum of ten).

Regards,

ABCTG

Reply With Quote
The following user says Thank You to ABCTG for this post:
 
  #3 (permalink)
Trading Apprentice
méxico df, méxico
 
Futures Experience: Advanced
Platform: ninjatrader, tradestation
Broker/Data: demo so far
Favorite Futures: stocks, fdax, fdxm, fesx, rb, ho, ng, cl, tf, nq, bp, ec, jy
 
Posts: 46 since Mar 2013
Thanks: 115 given, 21 received


thanks, i have been working on this development but haven't been able to make it work up to now.



right now the code looks like this, i only modified the structure for the entries/exits based on some information i found on some other internet pages:



if (long entry conditions met)... then begin


buy("hr") (PSize1) Shares next bar at open;
buy("lr") (PSize2) Shares next bar at open;
entr=c;

end;


sell("sl lr") next bar from entry("lr") (entr-sl) stop;
sell("sl hr") next bar from entry("hr") (entr-sl) stop;
sell("pt hr") next bar from entry("hr") (entr+pt2) limit;
sell("pt lr") next bar from entry("lr") (entr+pt1) limit;




setexitonclose;




so far only the first buy command is executed, whether i have the hr or lr command, only the one on top is filled. and, entryprice does not work, i am using close of last bar. if i change it to entr=entryprice; the strategy sells at the same spot it buys at.


are there any evident mistakes in this structure?


thanks.

Reply With Quote
 
  #4 (permalink)
Market Wizard
Hamburg Germany
 
Futures Experience: Advanced
Platform: Multicharts, Tradestation, Multicharts.NET, NinjaTrader, MetaTrader
Broker/Data: DTN IQ
Favorite Futures: ES
 
Posts: 1,533 since Apr 2013
Thanks: 231 given, 854 received
Forum Reputation: Legendary

maggtrading,

did you allow multiple entries in one direction? If not Tradestation might simply block the second entry although your code is correct. By default this is not enabled.
Go to the strategy properties and check "Allow up to ... entry orders in the same direction"

Please register on futures.io to view futures trading content such as post attachment(s), image(s), and screenshot(s).


I am not sure what you did with EntryPrice, but if you post the code I can take a look at it.

Regards,

ABCTG

Reply With Quote
The following user says Thank You to ABCTG for this post:
 
  #5 (permalink)
Trading Apprentice
méxico df, méxico
 
Futures Experience: Advanced
Platform: ninjatrader, tradestation
Broker/Data: demo so far
Favorite Futures: stocks, fdax, fdxm, fesx, rb, ho, ng, cl, tf, nq, bp, ec, jy
 
Posts: 46 since Mar 2013
Thanks: 115 given, 21 received

ABCTG,



danke schön.



effectively, once i changed the properties for all strategies i can get more than one position at once.


the code above seems to be working, so it should help in case anyone is searching for something similar.


now, i haven't been able to get the true entry price with the reserved word entryprice, the best approximation is - c -, the previous bar's close. i have tried entryprice, entryprice(0) and entryprice(1) but to no avail.

Reply With Quote
 
  #6 (permalink)
Trading Apprentice
méxico df, méxico
 
Futures Experience: Advanced
Platform: ninjatrader, tradestation
Broker/Data: demo so far
Favorite Futures: stocks, fdax, fdxm, fesx, rb, ho, ng, cl, tf, nq, bp, ec, jy
 
Posts: 46 since Mar 2013
Thanks: 115 given, 21 received

in the end i was able to code exactly what i was looking for: a hard limit profit target that drops only a fraction of a position. i share the code in case it can be of help for someone:


more profit target points can be added or removed using the same logic.




inputs: Price(Close),
pt1(1.7),
pt2(4),
psize1(100),
psize2(100);


variables:
MP(0),
ptp1(0),
ptp2(0);



MP = marketposition;




If MP = 1 then begin
ptp1 = Entryprice + pt1;
ptp1 = Entryprice + pt2;

End else
If MP = -1 then begin
ptp1 = Entryprice - pt1;
ptp2 = Entryprice - pt2;

End;



If Marketposition = 1 then begin

sell (psize1) Shares next bar ptp1 limit;
sell (psize2) Shares next bar ptp2 limit;


end;



If Marketposition = -1 then begin

Buy to cover (psize1) Shares next bar ptp1 limit;
Buy to cover (psize2) Shares next bar ptp2 limit;


end;

Reply With Quote
The following user says Thank You to maggtrading for this post:
 
  #7 (permalink)
Market Wizard
Hamburg Germany
 
Futures Experience: Advanced
Platform: Multicharts, Tradestation, Multicharts.NET, NinjaTrader, MetaTrader
Broker/Data: DTN IQ
Favorite Futures: ES
 
Posts: 1,533 since Apr 2013
Thanks: 231 given, 854 received
Forum Reputation: Legendary

maggtrading,

good job and thanks for sharing it.

Regards,
ABCTG

Reply With Quote

Reply



futures io > > > > modified profit target

Thread Tools Search this Thread
Search this Thread:

Advanced Search



Upcoming Webinars and Events (4:30PM ET unless noted)

Jigsaw Trading: TBA

Elite only

FuturesTrader71: TBA

Elite only

NinjaTrader: TBA

Jan 18

RandBots: TBA

Jan 23

GFF Brokers & CME Group: Futures & Bitcoin

Elite only

Adam Grimes: TBA

Elite only

Ran Aroussi: TBA

Elite only
     

Similar Threads
Thread Thread Starter Forum Replies Last Post
Profit Target with X_trader ReaM Trading Technologies 5 May 6th, 2014 11:07 AM
Profit target strategy DarkPoolTrading Traders Hideout 2 February 9th, 2013 01:40 AM
Setting a static profit target toddma NinjaTrader 4 July 31st, 2012 03:03 PM
What is the best way to work out your profit target? pyekorn Psychology and Money Management 14 July 22nd, 2010 02:14 AM
where should profit target be placed? anniebee321 Beginners and Introductions 9 June 7th, 2010 08:38 AM


All times are GMT -4. The time now is 11:02 PM.

Copyright © 2017 by futures io, s.a., Av Ricardo J. Alfaro, Century Tower, Panama, +507 833-9432, info@futures.io
All information is for educational use only and is not investment advice.
There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
no new posts
Page generated 2017-12-14 in 0.11 seconds with 20 queries on phoenix via your IP 54.90.207.75