How to use Next3rdFriday function ?  [SOLVED]

Questions about MultiCharts and user contributed studies.
paul.robillard
Posts: 30
Joined: 22 Mar 2012
Location: Western Europe
Has thanked: 6 times

How to use Next3rdFriday function ?

Postby paul.robillard » 20 Nov 2015

The Function Next3rdFriday needs an argument. What should be the argument ?

I tought

Code: Select all

Next3rdFriday(dayofmonth(1))

but no.

What i am looking trying to achieve is to draw a vertical bar on the option expiry day.

User avatar
TJ
Posts: 7743
Joined: 29 Aug 2006
Location: Global Citizen
Has thanked: 1033 times
Been thanked: 2222 times

Re: How to use Next3rdFriday function ?  [SOLVED]

Postby TJ » 20 Nov 2015

Next3rdFriday (Function)

The Next3rdFriday function calculates the number of calendar days to the next 3rd Friday of a month.

Syntax
Next3rdFriday( Series )

Returns (Integer)
A numeric value containing the number of calendar days to the 3rd Friday of the Nth month ahead.

Parameters

Series -- Numeric

Sets the months (ahead) to get the next 3rd Friday. 0=current month, 1=next month, and so on.

Remarks
For the current month, Next3rdFriday(0) will return a negative number of days if the current day of the current month is past the 3rd Friday. In a similar manner, Next3rdFriday(1) returns the number of days to the next 3rd Friday even if it is in the same month as the current day.

Example
If you want to exit out of long positions ten days before the 3rd Friday of the coming month, you can write

If Next3rdFriday(1) <= 10 Then
Sell Next Bar at Market;

User avatar
TJ
Posts: 7743
Joined: 29 Aug 2006
Location: Global Citizen
Has thanked: 1033 times
Been thanked: 2222 times

Re: How to use Next3rdFriday function ?

Postby TJ » 20 Nov 2015

You can google for this free ebook:

EasyLanguage® Functions & Reserved Words Reference

paul.robillard
Posts: 30
Joined: 22 Mar 2012
Location: Western Europe
Has thanked: 6 times

Re: How to use Next3rdFriday function ?

Postby paul.robillard » 20 Nov 2015

Thank you !

I will get the ebook.


Return to “MultiCharts”