Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Reference Point Dummy Entry

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Reference Point Dummy Entry

    I have been creating reference points for
    MarketPosition.Short and MarketPosition.Long
    that I could use later as a condition.
    It works for the most part except that instead of entering at the 0 position size,
    NT8 enters at 1 which I assume is the minimum.
    Is there any way to have those reference points of Long/Short
    without actually entering with the quantity of 1?

    Is there another way I could do something similar?

    Code:
    If (CrossBelow(SMA2, SMA1, 1))
    {
    EnterShort(0, 0,"DummyShort");
    }
    
    if (PositionAccount.Quantity >= 1)
    && (Position.MarketPosition == MarketPosition.Short)
    {
              EnterShort(0, Quantity,"RealShort");
    }

    #2
    Hello johnnybegoode,

    Thanks for your post.

    The MarketPosition of Long or short is only created when you have an entry order that has been filled.

    I suspect that you want to do is to create a bool variable (that can only be true or false) and use that as a reference point when a cross condition occurs. You can then use that bool in another set as part of a set of entry conditions. In that set then where you place the actual entry order, you could then set the bool to false to prevent further entry based on that crossover until the next crossover occurs.

    I may not have understood your objective so if my reply does not meet your needs, please post again perhaps with another example.

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by NullPointStrategies, Today, 05:17 AM
    0 responses
    41 views
    0 likes
    Last Post NullPointStrategies  
    Started by argusthome, 03-08-2026, 10:06 AM
    0 responses
    124 views
    0 likes
    Last Post argusthome  
    Started by NabilKhattabi, 03-06-2026, 11:18 AM
    0 responses
    64 views
    0 likes
    Last Post NabilKhattabi  
    Started by Deep42, 03-06-2026, 12:28 AM
    0 responses
    41 views
    0 likes
    Last Post Deep42
    by Deep42
     
    Started by TheRealMorford, 03-05-2026, 06:15 PM
    0 responses
    46 views
    0 likes
    Last Post TheRealMorford  
    Working...
    X