NexusFi: Find Your Edge


Home Menu

 





barssinceentry


Discussion in MultiCharts

Updated
    1. trending_up 1,348 views
    2. thumb_up 0 thanks given
    3. group 2 followers
    1. forum 1 posts
    2. attach_file 0 attachments




 
Search this Thread
  #1 (permalink)
alexbellinzona
Lugano Switzerland
 
Posts: 11 since Apr 2016
Thanks Given: 6
Thanks Received: 3

Hi everyone,

I've a little problem with the "barssinceentry" word.

If I write in the code:

if marketposition = 1 and barssinceentry > 10 then sell next bar at market;

In backtesting it works perfectly but when in live trading it does not close any position after 10 bars. I really can not understand what's wrong.

Anyone can help?

Many thanks!!!

Reply With Quote

Can you help answer these questions
from other members on NexusFi?
Historical data for Kospi and Nikkei Index
NinjaTrader
Volumetric charts
The Elite Circle
Quantum physics & Trading dynamics
The Elite Circle
MC Advanced Simulated Trading.
MultiCharts
Pivot Indicator based on Level2 data
NinjaTrader
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
ApexTraderFunding.com experience and review
84 thanks
What is Markets Chat (markets.chat) real-time trading ro …
53 thanks
HumbleTraders next chapter
39 thanks
1 Minute Man
22 thanks
Tao te Trade: way of the WLD
17 thanks
  #2 (permalink)
 ABCTG   is a Vendor
 
Posts: 2,439 since Apr 2013
Thanks Given: 486
Thanks Received: 1,629

alexbellinzona,

the code you posted should work fine in backtesting and live trading. Based on that the problem might be related to something else, which is hard to tell without knowing your full code and the exact steps you did to produce this situation.
For example barssinceentry will not rememeber the hístory when you assign a broker position to your signal when you enable the automation. This could lead to something appearing to be off, but without knowing what you did, this is just meant to be an example of what can go wrong and not as explanation.

Regards,

ABCTG

Follow me on Twitter Reply With Quote




Last Updated on December 25, 2016


© 2024 NexusFi™, s.a., All Rights Reserved.
Av Ricardo J. Alfaro, Century Tower, Panama City, Panama, Ph: +507 833-9432 (Panama and Intl), +1 888-312-3001 (USA and Canada)
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.
About Us - Contact Us - Site Rules, Acceptable Use, and Terms and Conditions - Privacy Policy - Sitemap - Downloads - Top
no new posts