Seasonality Analysis with In Sample and Out of Sample and Monthly Rating

v10.3
Seasonality Analysis with In Sample and Out of Sample and Monthly Rating

This is a further development of my Seasonality Analysis Indicator that analyses historical data month by month to test for the seasonality of any market.

Apply only on Monthly charts.

In this version you can select a period to be tested as in sample and  a period to be tested as out of sample. Comparison of the two allows more accurate analysis of the results.

You can set any number of years for each sample period but be aware that short data samples will not include much data. For example there are only five of each month in a five year sample.

You must set the current month before each test. 1 = Jan and 12 = Dec.

If you set fifteen years for the in sample and ten years for the out of sample then the analysis will start twenty five years back from today. The in sample will be tested on the first fifteen years and and the out of sample on the last ten.

The results you are interested in are the last ones under the current months candle and I suggest making the indicator window full size to make it easier to read.

The result categories are as follows:

Return: The average pips return in that month over the period tested. If you had opened a long bet at the beginning of that month and closed it at the end of that month every year then this is how much you would have gained or lost on average each month.

Rank%: The best performing monthly average return and the worst performing monthly average return are ranked at 100% and -100%. All months in between are given a ranking% relative to these. This is useful if you want to alter position sizing in a strategy month by month based on seasonality. You might want to place position size of 100% of your maximum bet size in months rated at 100% and only 33% in months rated 33% for example.

Reliability%: The number of up months and number of down months are totalled up and a reliability percentage calculated. For example if you test over 10 years and have ten tests of January and January’s results favour long positions then if 7 of those months see a gain and 3 a loss then the reliability is 70%. You may wish to only go long in months with a Reliability% of over 70% for example.  This reliability% helps you decide the probability of future results matching historical results.

Rating Score: The in sample and out of sample Rank% and Reliability% are combined and converted into this score. Twice as much weight is given to the more recent out of sample data. A very low score indicates a very good month to enter short trades and a very high score a very good month to enter long trades. The rating can also be used to decide on position size and preferred trade direction for trades month by month. This rating system is unproven and will obviously vary depending on the length of sample periods chosen – so use at your discretion.

If this indicator is used alongside my other two indicators Seasonality Analysis and Seasonality Analysis Graph then any trader should be easily be able to make good decisions on when is a good time to trade long or short and whether to increase or decrease position size month by month for any market where sufficient data is available.

I advise downloading and importing the .itf file to ensure that you get full functionality.

Share this

Risk disclosure:

No information on this site is investment advice or a solicitation to buy or sell any financial instrument. Past performance is not indicative of future results. Trading may expose you to risk of loss greater than your deposits and is only suitable for experienced investors who have sufficient financial means to bear such risk.

ProRealTime ITF files and other attachments : How to import ITF files into ProRealTime platform?

PRC is also on YouTube, subscribe to our channel for exclusive content and tutorials

  1. Alai-n • 01/11/2018 #

    Hello Vonasi, In the same spirit as this table would you have something similar to analyze on daily data. In order to determine in the long run if a Monday is rather hauled or lowered, Tuesday, Wednesday etc .

  2. Vonasi • 01/11/2018 #

    Sorry but I don’t have anything like that at the moment. This thread might be of interest to you though https://www.prorealcode.com/topic/investor-behavior/page/2/ . I have put on there a strategy that can be run to analyse buying at each hour of each day and then selling after a preset length of time. You can use this to work out which days and which hours have been historically better times to trade long.

  3. Alai-n • 01/11/2018 #

    Too bad for my question … 😉 And thank you for the link!

  4. ALE • 01/11/2018 #

    Very Very Good!

  5. Vonasi • 01/11/2018 #

    Thanks for the compliments ALE. If you use any results from it in a strategy then please share as you usually do!

  6. CKW • 01/11/2018 #

    this is Awesome tool. thanks Vonasi

  7. Vonasi • 01/11/2018 #

    ….and thank you for the compliment CKW.

avatar
Register or

Likes

avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar

+2 more likes

Related users ' posts
JohnScher I've been looking for this for a long time! A very big thank you to you.
Nupsator hi, looks very interesting, i imported the indicator and inserted it into a 1h chart. Unfort...
Ciccarelli Franco Lo trovo interessante, ma non riesco a scaricarlo. Chi mi può aiutare?
klaus_reum Many thanks for that great tool. nevertheless, I am struggling with the time range. I tried ...
ipbvba idem ne fonctionne pas sur V11 (meme avec real time data), import OK mais aucune courbe dans...
Ciccarelli Franco I'm new to the Market, I imported the code, but I don't see anything, there is an empty box ...
ALE Very Very Nice
manel Hi - Many thanks for this and your other analytical codes, stellar work - very useful ! With...
Vonasi Good idea Manel. I have posted a new version here that shows results as a percentage: https:...
Vonasi No problem pableitor - I'm glad you like it.
pableitor Hi Vonasi, I was checking a few random weeks with your indicator and sometimes it seems to ...
Vonasi I have not checked your query on a chart but my guess is that you are reading the indicator ...
Reiner great work:-)
Vonasi Thanks Reiner. that is compliments indeed from the seasonality expert. I have a second vers...
Sagal Hi Vonasi, Can it be presented as a 1 year graph displaying a 5 year average or 10 year aver...
Yannick TradingDayLong = dayofweek = 1 or dayofweek = 2 or dayofweek = 3 or dayofweek = 4 or dayof...
Marlon Hey JohnScher, your code works fine, but my results aren't as good as yours. Even if I use ...
DarioMazza Bha... this code dont work. gg
Reiner
8 years ago
Nicolas You should join and read the forum thread about this strategy. There are plenty of different...
Reiner Hi djtaktik and welcome, I have answered your question in the related Pathfinder forum beca...
danver34 is this version the definitive one or from the original one have there been modifications to...

Top