RealTest User Guide
RealTest User Guide

 

 

Navigation: Realtest Script Language > Syntax Element Details >

MaxNetExp

 

 

 

 

Category

Strategy Elements

Description

Maximum net long-short position exposure for a strategy or group of strategies

Input

Any formula specifying a percentage

Notes

MaxNetExp is one of the Capacity Constraints formulas used in the setup selection process.

A setup is only selected if its signed position size plus those of other setups selected so far plus current net S.LongExp - S.ShortExp of open positions divided by current S.Alloc would not exceed the percentage expressed as MaxNetExp. (In practice only a long setup could trigger this constraint.)

If a setup cannot be selected due to this constraint and the strategy specifies Reduce: True, then the position's Quantity will be reduced to allow the position to be ordered for entry at smaller size if possible.

Setups skipped for this reason display "max net exp" in the Reason column of the Trade List, provided that the KeepTrades setting included Skipped.

If MaxNetExp is not specified then there is no upper limit placed on net percent exposure, though there might still be a net investment upper limit if the strategy specifies MaxNetInv.

Note that opening gaps beyond a specified order price may cause actual long exposure to exceed the specified cap in some situations -- think of this constraint as "maximum intended net exposure".

See Also: Backtest Engine Details and Capacity Constraints

 

 

 

 

Copyright © 2020-2025 Systematic Solutions, LLC