{"id":1988241,"date":"2014-04-24T13:19:10","date_gmt":"2014-04-24T07:49:10","guid":{"rendered":"http:\/\/stockviz.biz\/index.php\/?p=1988241"},"modified":"2014-09-09T12:07:24","modified_gmt":"2014-09-09T06:37:24","slug":"nifty-statistical-study","status":"publish","type":"post","link":"https:\/\/stockviz.biz\/index.php\/2014\/04\/24\/nifty-statistical-study\/","title":{"rendered":"Nifty Statistical Study"},"content":{"rendered":"<h3>Returns vs. Log Returns<\/h3>\n<p>We had discussed how the <a title=\"returns are normally distributed\" href=\"http:\/\/stockviz.biz\/index.php\/2014\/04\/18\/important-assumption\/\" target=\"_blank\">most important assumption<\/a> in finance is that returns are normally distributed. Also, the benefit of using <em>returns<\/em>, versus <em>prices<\/em>, is normalization. All your variables are now on the same scale and can be compared easily. But if you pick up any book on financial statistical modelling, you&#8217;ll run into log returns more often.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-1988251\" alt=\"nifty-daily-returns\" src=\"http:\/\/portalvhds29z8xdrqhczq.blob.core.windows.net\/wordpress\/2014\/04\/nifty-daily-returns.png\" width=\"640\" height=\"480\" srcset=\"https:\/\/portalvhds29z8xdrqhczq.blob.core.windows.net\/wordpress\/2014\/04\/nifty-daily-returns.png 640w, https:\/\/portalvhds29z8xdrqhczq.blob.core.windows.net\/wordpress\/2014\/04\/nifty-daily-returns-300x225.png 300w, https:\/\/portalvhds29z8xdrqhczq.blob.core.windows.net\/wordpress\/2014\/04\/nifty-daily-returns-400x300.png 400w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-1988261\" alt=\"nifty-daily-log-returns\" src=\"http:\/\/portalvhds29z8xdrqhczq.blob.core.windows.net\/wordpress\/2014\/04\/nifty-daily-log-returns.png\" width=\"640\" height=\"480\" srcset=\"https:\/\/portalvhds29z8xdrqhczq.blob.core.windows.net\/wordpress\/2014\/04\/nifty-daily-log-returns.png 640w, https:\/\/portalvhds29z8xdrqhczq.blob.core.windows.net\/wordpress\/2014\/04\/nifty-daily-log-returns-300x225.png 300w, https:\/\/portalvhds29z8xdrqhczq.blob.core.windows.net\/wordpress\/2014\/04\/nifty-daily-log-returns-400x300.png 400w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/p>\n<p>As you can see from the charts above, visually, they don&#8217;t make a difference. However, taking the log of returns makes the math easier:<\/p>\n<ol>\n<li>If we assume that prices are distributed <strong style=\"color: #000000;font-style: normal\">log normally<\/strong>, then log(1+r<sub style=\"color: #000000;font-style: normal\">i<\/sub>), where r<sub style=\"color: #000000;font-style: normal\">i<\/sub> is the <em style=\"color: #000000\">i<sup>th<\/sup><\/em> period return, is <strong style=\"color: #000000;font-style: normal\">normally<\/strong> distributed. And we know how to work with normal distributions.<\/li>\n<li>When returns are very small, log(1+r<sub style=\"color: #000000;font-style: normal\">i<\/sub>) \u2248 r<\/li>\n<li>Calculating compounding return goes from series multiplication (\u220f) to series summation (\u2211).<\/li>\n<\/ol>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-1988271\" alt=\"nifty-histogram\" src=\"http:\/\/portalvhds29z8xdrqhczq.blob.core.windows.net\/wordpress\/2014\/04\/nifty-histogram.png\" width=\"640\" height=\"480\" srcset=\"https:\/\/portalvhds29z8xdrqhczq.blob.core.windows.net\/wordpress\/2014\/04\/nifty-histogram.png 640w, https:\/\/portalvhds29z8xdrqhczq.blob.core.windows.net\/wordpress\/2014\/04\/nifty-histogram-300x225.png 300w, https:\/\/portalvhds29z8xdrqhczq.blob.core.windows.net\/wordpress\/2014\/04\/nifty-histogram-400x300.png 400w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-1988281\" alt=\"nifty-log-histogram\" src=\"http:\/\/portalvhds29z8xdrqhczq.blob.core.windows.net\/wordpress\/2014\/04\/nifty-log-histogram.png\" width=\"640\" height=\"480\" srcset=\"https:\/\/portalvhds29z8xdrqhczq.blob.core.windows.net\/wordpress\/2014\/04\/nifty-log-histogram.png 640w, https:\/\/portalvhds29z8xdrqhczq.blob.core.windows.net\/wordpress\/2014\/04\/nifty-log-histogram-300x225.png 300w, https:\/\/portalvhds29z8xdrqhczq.blob.core.windows.net\/wordpress\/2014\/04\/nifty-log-histogram-400x300.png 400w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/p>\n<h3>Quantiles<\/h3>\n<p>The easiest way to\u00a0summarize a frequency distribution\u00a0is through quantiles. Quantiles are values which divide the distribution such that there is a given proportion of observations below the quantile. For example, the median is a quantile such that half the points are less than or equal to it and half are greater than or equal to it.<\/p>\n<p><strong>Raw-returns (%):<\/strong><\/p>\n<div class=\"row-fluid\">\n<table class=\"table table-bordered table-condensed\">\n<tbody>\n<tr>\n<td>1%<\/td>\n<td>5%<\/td>\n<td>25%<\/td>\n<td>50%<\/td>\n<td>75%<\/td>\n<td>95%<\/td>\n<td>99%<\/td>\n<\/tr>\n<tr>\n<td>-4.1986<\/td>\n<td>-2.4994<\/td>\n<td>-0.6992<\/td>\n<td>0.0967<\/td>\n<td>0.8585<\/td>\n<td>2.4387<\/td>\n<td>4.4465<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<p><strong>Log-returns:<\/strong><\/p>\n<div class=\"row-fluid\">\n<table class=\"table table-bordered table-condensed\">\n<tbody>\n<tr>\n<td>1%<\/td>\n<td>5%<\/td>\n<td>25%<\/td>\n<td>50%<\/td>\n<td>75%<\/td>\n<td>95%<\/td>\n<td>99%<\/td>\n<\/tr>\n<tr>\n<td>-0.04289<\/td>\n<td>-0.0253<\/td>\n<td>-0.0070<\/td>\n<td>0.0009<\/td>\n<td>0.0085<\/td>\n<td>0.0240<\/td>\n<td>0.0435<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<h3>Q-Q Plot<\/h3>\n<p>Once we know the qunatiles of our log returns, we can compare it to that of a normal distribution. When you plot the quantiles of the sample (Nifty daily log returns) to the quantiles of a theoretical normal distribution, you get a visual feel for the outliers &#8211; the fat tails.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-1988381\" alt=\"nifty-log-returns-normal-qq-plot\" src=\"http:\/\/portalvhds29z8xdrqhczq.blob.core.windows.net\/wordpress\/2014\/04\/nifty-log-returns-normal-qq-plot.png\" width=\"640\" height=\"480\" srcset=\"https:\/\/portalvhds29z8xdrqhczq.blob.core.windows.net\/wordpress\/2014\/04\/nifty-log-returns-normal-qq-plot.png 640w, https:\/\/portalvhds29z8xdrqhczq.blob.core.windows.net\/wordpress\/2014\/04\/nifty-log-returns-normal-qq-plot-300x225.png 300w, https:\/\/portalvhds29z8xdrqhczq.blob.core.windows.net\/wordpress\/2014\/04\/nifty-log-returns-normal-qq-plot-400x300.png 400w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/p>\n<p>This plot shows that both tails are heavier than the tails of the normal distribution. So, although using log returns and assuming that prices are distributed log normally makes the math easier, we should always be aware that it is a sleight of hand.<\/p>\n<p><em>To be continued&#8230;<\/em><\/p>\n<p><strong>Sources:<\/strong><\/p>\n<ul>\n<li><a style=\"font-style: normal\" href=\"http:\/\/quantivity.wordpress.com\/2011\/02\/21\/why-log-returns\/\" target=\"_blank\">Why Log Returns<\/a><\/li>\n<li><a style=\"font-style: normal\" href=\"http:\/\/www-users.york.ac.uk\/~mb55\/intro\/quantile.htm\" target=\"_blank\">Medians and quantiles<\/a><\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>Returns vs. Log Returns We had discussed how the most important assumption in finance is that returns are normally distributed. Also, the benefit of using returns, versus prices, is normalization. All your variables are now on the same scale and can be compared easily. But if you pick up any book on financial statistical modelling, &hellip; <\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3471,9],"tags":[2761],"class_list":["post-1988241","post","type-post","status-publish","format-standard","hentry","category-investing-insight","category-your-money","tag-quant","entry"],"_links":{"self":[{"href":"https:\/\/stockviz.biz\/index.php\/wp-json\/wp\/v2\/posts\/1988241","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/stockviz.biz\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/stockviz.biz\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/stockviz.biz\/index.php\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/stockviz.biz\/index.php\/wp-json\/wp\/v2\/comments?post=1988241"}],"version-history":[{"count":0,"href":"https:\/\/stockviz.biz\/index.php\/wp-json\/wp\/v2\/posts\/1988241\/revisions"}],"wp:attachment":[{"href":"https:\/\/stockviz.biz\/index.php\/wp-json\/wp\/v2\/media?parent=1988241"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/stockviz.biz\/index.php\/wp-json\/wp\/v2\/categories?post=1988241"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/stockviz.biz\/index.php\/wp-json\/wp\/v2\/tags?post=1988241"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}