![]() |
This website will be down for maintenance from Friday May 24th at 6PM MDT until Saturday May 25th at 11AM MDT. We apologize for the inconvenience. If you need assistance during this time, please email sales@ninjatrader.com
|
|||||||
| Version 7 Beta General Questions & Bug Reports Ask questions here and post bug reports. |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Senior Member
Join Date: Sep 2009
Posts: 186
Thanks: 0
Thanked 0 times in 0 posts
|
in NT7 sim, don't see values of Unrealized and Realized in Strategy Tab while they are enabled and know, it has some PnL. should I have to change parameters somewhere?
|
|
|
|
|
|
#2 |
|
NinjaTrader Customer Service
Join Date: Sep 2009
Location: Denver, CO
Posts: 8,117
Thanks: 249
Thanked 418 times in 415 posts
|
Hello Kumaresh11,
Can you please post a screenshot of your strategy tab? To send a screenshot press Alt + PRINT SCREEN to take a screen shot of the selected window. Then go to Start--> Accessories--> Paint, and press CRTL + V to paste the image. Lastly, save as a jpeg file and send the file as an attachment.
Ryan M
NinjaTrader Customer Service |
|
|
|
|
|
#3 |
|
Senior Member
Join Date: Aug 2010
Location: Locust Valley, NY
Posts: 102
Thanks: 0
Thanked 0 times in 0 posts
|
Same issue here.
The PnL unrealized Does show in Positions tab, but not Strategies. Also, many NT code references to open p&l, closed p&l seem to be ignored (i expect it's same problem). 7.23 |
|
|
|
|
|
#4 |
|
NinjaTrader Customer Service
Join Date: Sep 2009
Location: Denver, CO
Posts: 8,117
Thanks: 249
Thanked 418 times in 415 posts
|
The strategies tab will only list PnL generated by that particular strategy instance. It does not show PnL when waiting for a flat state and the wait until flat option is set.
Can you please post a screenshot of your strategies tab so we can isolate what may be happening?
Ryan M
NinjaTrader Customer Service |
|
|
|
|
|
#5 |
|
Senior Member
Join Date: Aug 2010
Location: Locust Valley, NY
Posts: 102
Thanks: 0
Thanked 0 times in 0 posts
|
OK, see the attached 2 shots (move to far R).
BTW, these are launched from NT code as ATM strats, and managed by DOM/ATM. |
|
|
|
|
|
#6 |
|
NinjaTrader Customer Service
Join Date: Dec 2009
Location: Denver, CO, USA
Posts: 6,498
Thanks: 109
Thanked 291 times in 280 posts
|
Hello,
Thanks for the screenshot. The only issue here is that we cannot tell weather the positions where generated by the strategy. I see some output window text but I dont see really anythign that corresponds. For us to correspond this in we would also need the log file. Please send the log file to support at ninjatrader dot com and put ATTN: Ryan and also put in the subject line a link to this forum post. Please send the following file as an attachment. My Documents--> NinjaTrader 7--> Log--> log.2010051108 for today. (log.yyyymmdd for any other date) Thanks again for sending in.
Brett
NinjaTrader Customer Service |
|
|
|
|
|
#7 |
|
NinjaTrader Customer Service
Join Date: Dec 2009
Location: Denver, CO, USA
Posts: 6,498
Thanks: 109
Thanked 291 times in 280 posts
|
Hello,
Thanks for sending that in, I'm also posting here for other to benefit from. You are using ATM Strategies with your NinjaScript Strategy. Essentially what occurs when you use an ATM Strategy the PnL and Position/Avg price information is stored in this secondary Sub Strategy that is running/created and is no longer maintained by the host strategy. Since the ATM Strategy is managing the position now. Since your using ATM Strategies this information will only be displayed on the chart or the DOM Unfortunately at this time since the NinjaScript strategy is not managing the position it cannot display the position information. Since it does not know what is occurring inside that ATM Strategy. This is something that development is aware of however it is working as expected currently. Let me know if I can be of further assistance.
Brett
NinjaTrader Customer Service |
|
|
|
|
|
#8 |
|
Senior Member
Join Date: Aug 2010
Location: Locust Valley, NY
Posts: 102
Thanks: 0
Thanked 0 times in 0 posts
|
Related to this:
From Ninja script 7.23, i launch a 2-contract ATM. I can see both working in the ATM. When i try to modify the stop loss level, it seems to only modify one of the orders. How do i access both the contracts? and is there a way i can check on the current stop level? i havent found anything in the 7-handbook launching the strategy: atmStrategyIdL = GetAtmStrategyUniqueId(); orderIdL = GetAtmStrategyUniqueId(); AtmStrategyCreate(OrderAction.Buy, OrderType.Limit, longEntry, 0, TimeInForce.Day, orderIdL, myAtm, atmStrategyIdL); } tightening the stop level: private void TightenStopL(int amount, string reason) { drawColor = Color.White; if (atmStrategyIdL.Length > 0) { if (GetAtmStrategyMarketPosition(atmStrategyIdL) == MarketPosition.Long) { newStop = Low[0]-amount*TickSize; if (_debug2); Print(Time[0].ToString()+header+ " Tightening LONG stops to " + newStop + " "+reason); drawColor = Color.Red; //DrawDiamond("newstop"+currentBar, true, 0, newStop, Color.White); if (takeExits) AtmStrategyChangeStopTarget(0, newStop, "STOP1", atmStrategyIdL); PlaySound(@"C:\Program Files\NinjaTrader 7\sounds\autotrail.wav"); } } DrawText("tgt"+CurrentBar, "tgtn", live, newStop, drawColor); } |
|
|
|
|
|
#9 |
|
NinjaTrader Customer Service
Join Date: Sep 2009
Location: Denver, CO
Posts: 8,117
Thanks: 249
Thanked 418 times in 415 posts
|
Hello ssylwester,
Are you trying to change manually or through code? Through code, you can use: http://www.ninjatrader.com/support/h...stoptarget.htm If you're looking to get the status of your stop loss: http://www.ninjatrader.com/support/h...rgetorders.htm
Ryan M
NinjaTrader Customer Service |
|
|
|
|
|
#10 |
|
Senior Member
Join Date: Aug 2010
Location: Locust Valley, NY
Posts: 102
Thanks: 0
Thanked 0 times in 0 posts
|
Hi Ryan, thanks for the response. I'm changing it through code. in fact, i included the code in the original posting. But the code only changes 1 of the 2 orders.
|
|
|
|
|
|
#11 |
|
NinjaTrader Customer Service
Join Date: Sep 2008
Location: Germany
Posts: 22,404
Thanks: 252
Thanked 974 times in 957 posts
|
You would need to the same call to change for STOP2 then, right now you only call STOP1 for a change in your snippet provided.
Bertrand
NinjaTrader Customer Service |
|
|
|
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| unrealized/realized valuta symbol wrong currency | zweistein | Version 7 Beta General Questions & Bug Reports | 7 | 06-10-2010 09:43 AM |
| Understanding realized and unrealized p/l | skat100 | Miscellaneous Support | 1 | 12-16-2008 04:09 PM |
| Unrealized and Realized PnL in points/pips and % in stead of only $ | whitegun | Suggestions And Feedback | 22 | 11-14-2008 05:54 PM |
| Unrealized + realized profits? | Ninja B | Automated Trading | 2 | 10-08-2008 06:57 AM |
| No Money in unrealized or realized for Forex | jlm0@infionline.net | Historical NinjaTrader 6.5 Beta Threads | 5 | 11-12-2007 10:35 AM |