×

Sign up and get MultiCharts free

Use its powerful simulation mode with data included out of the box. Just fill out the form and start honing your trading skills with a few clicks.

Difference between revisions of "CurrentContracts" - MultiCharts
Open main menu

Difference between revisions of "CurrentContracts"

m (Reverted edits by 176.8.90.7 (talk) to last revision by JoshM)
 
(2 intermediate revisions by one other user not shown)
Line 1: Line 1:
 
Returns an absolute numerical value, indicating the number of contracts or shares held in the current position.  
 
Returns an absolute numerical value, indicating the number of contracts or shares held in the current position.  
 
   
 
   
http://www.buyxanaxonlinepill.com/ xanax cheap - order xanax online overnight
+
== Usage ==
 
+
<syntaxhighlight>CurrentContracts</syntaxhighlight>
 +
 
== Notes ==  
 
== Notes ==  
 
* This function can only be used in signals.  
 
* This function can only be used in signals.  

Latest revision as of 12:42, 13 February 2012

Returns an absolute numerical value, indicating the number of contracts or shares held in the current position.

Usage

CurrentContracts

Notes

Example

CurrentContracts

Will return a value of "1" if the strategy is long 1 contract or share.

CurrentContracts

Will return a value of "5" for 5 shares short.

CurrentContracts returns an absolute value for both long and short positions. Multiply it with the MarketPosition to get the negative sign for short positions. For example:

MarketPosition(0) * CurrentContracts

Will return a value of "-9" if the strategy is short 9 contracts, and will return a value of "4" if the strategy is long four contracts.