<p><div><div><div><div data-width="100" data-show-faces="false" data-send="true" data-layout="button_count" data-height="21" data-href="https://www.r-bloggers.com/prediction-intervals-for-glms-part-i/"></div></div><div></div></div><div></div></div>
<div>
(This article was first published on <strong><a href="http://www.fromthebottomoftheheap.net/2017/05/01/glm-prediction-intervals-i/"> From the Bottom of the Heap - R</a></strong>, and kindly contributed to <a rel="nofollow" href="https://www.r-bloggers.com/">R-bloggers)</a> </div>
<p>
One of my more popular <a target="_blank" rel="nofollow" href="http://stackoverflow.com/a/14424417/429846">answers</a> on StackOverflow concerns the issue of prediction intervals for a generalized linear model (GLM). My answer really only addresses how to compute confidence intervals for parameters but in the comments I discuss the more substantive points raised by the OP in their question. Lately there’s been a bit of back and forth between Jarrett Byrnes and myself about what a prediction “interval” for a GLM might mean. Comments, even on StackOverflow, aren’t a good place for a discussion so I thought I’d post something here that went into a bit more detail as to why, for some common types of GLMs, prediction intervals aren’t that useful and require a lot more thinking about what they mean and how they should be calculated. For illustration, I thought I’d use some small teaching example data sets, but whilst writing the post it started to get a little on the long side. So, I’ve broken it into two and in this part I look at logistic regression.
</p>
<p>
The first example concerns a small experiment on the rare insectivorous pitcher plant <em>Darlingtonia californica</em> (the cobra lily) used as an example in <span data-cites="Gotelli2013-wm">Gotelli and Ellison (2013)</span> and originally reported in <span data-cites="Dixon2005-bb">Dixon et al. (2005)</span>. <em>Darlingtonia</em> grows leaves that are modified to form a pitcher trap, which is filled with nectar that attracts insects, in particular vespulid wasps (<em>Vespula atropilosa</em>). The observations in the data set are on the height of pitcher traps (<code>leafHeight</code>) and whether or not the leaf was visited by a wasp (<code>visited</code>). The code chunk below downloads the data from the book’s website and loads it into R ready for use.
</p>
<figure>
<pre><code data-lang="r"><span>darlurl</span> <span>&lt;-</span> <span>&quot;http://harvardforest.fas.harvard.edu/sites/harvardforest.fas.harvard.edu/files/ellison-pubs/2004/DarlingtoniaData3.txt&quot;</span>
<span>darl</span> <span>&lt;-</span> <span>setNames</span><span>(</span><span>read.fwf</span><span>(</span><span>darlurl</span><span>,</span> <span>widths</span> <span>=</span> <span>c</span><span>(</span><span>8</span><span>,</span><span>9</span><span>),</span> <span>header</span> <span>=</span> <span>FALSE</span><span>,</span> <span>skip</span> <span>=</span> <span>1L</span><span>),</span>
                 <span>c</span><span>(</span><span>&quot;leafHeight&quot;</span><span>,</span> <span>&quot;visited&quot;</span><span>))</span>
<span>darl</span> <span>&lt;-</span> <span>transform</span><span>(</span><span>darl</span><span>,</span> <span>visited</span> <span>=</span> <span>as.logical</span><span>(</span><span>visited</span><span>))</span></code></pre>
</figure>
<p>
Kernel density estimates of the distributions of the leaf heights for visited and unvisited leaves is one way to visualise these data. Here we use <strong>ggplot2</strong>
</p>
<figure>
<pre><code data-lang="r"><span>library</span><span>(</span><span>&quot;ggplot2&quot;</span><span>)</span>
<span>theme_set</span><span>(</span><span>theme_bw</span><span>())</span>

<span>xlab</span> <span>&lt;-</span> <span>&quot;Leaf height [cm]&quot;</span>
<span>ggplot</span><span>(</span><span>darl</span><span>,</span> <span>aes</span><span>(</span><span>x</span> <span>=</span> <span>leafHeight</span><span>,</span> <span>colour</span> <span>=</span> <span>visited</span><span>))</span> <span>+</span>
    <span>geom_line</span><span>(</span><span>stat</span> <span>=</span> <span>&quot;density&quot;</span><span>)</span> <span>+</span> <span>labs</span><span>(</span><span>x</span> <span>=</span> <span>xlab</span><span>,</span> <span>y</span> <span>=</span> <span>&quot;Density&quot;</span><span>)</span></code></pre>
</figure>
<figure>
<img alt="Kernel density estimates of the distribution of heights of leaves visited or not by wasps." src="https://i2.wp.com/www.fromthebottomoftheheap.net/assets/img/posts/glm-prediction-intervals-i-load-packages-plot-darlingtonia-1.png?w=456" data-recalc-dims="1">
<figcaption>
Kernel density estimates of the distribution of heights of leaves visited or not by wasps.<br>
</figcaption>
</figure>
<p>
We’re interested in modelling the probability of leaf visitation as a function of leaf height. For this a binomial GLM is a logical choice, with the canonical link function, the logit or logistic function. Such a model is fitted using <code>glm()</code> as follows
</p>
<figure>
<pre><code data-lang="r"><span>m</span> <span>&lt;-</span> <span>glm</span><span>(</span><span>visited</span> <span>~</span> <span>leafHeight</span><span>,</span> <span>data</span> <span>=</span> <span>darl</span><span>,</span> <span>family</span> <span>=</span> <span>binomial</span><span>)</span>
<span>summary</span><span>(</span><span>m</span><span>)</span></code></pre>
</figure>
<figure>
<pre><code data-lang="text">Call:
glm(formula = visited ~ leafHeight, family = binomial, data = darl)

Deviance Residuals: 
     Min        1Q    Median        3Q       Max  
-2.18274  -0.46820  -0.23897  -0.08519   1.90573  

Coefficients:
            Estimate Std. Error z value Pr(>|z|)    
(Intercept) -7.29295    2.16081  -3.375 0.000738 ***
leafHeight   0.11540    0.03655   3.158 0.001591 ** 
---
Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

(Dispersion parameter for binomial family taken to be 1)

    Null deviance: 46.105  on 41  degrees of freedom
Residual deviance: 26.963  on 40  degrees of freedom
AIC: 30.963

Number of Fisher Scoring iterations: 6</code></pre>
</figure>
<p>
The model summary suggests an effect of leaf height that is unlikely to be observed if there were no effect. For a unit increase in leaf height, the odds of visitation increase by 1.12 times (given by <code>exp(coef(m)[2])</code>).
</p>
<p>
How the probability of visitation varies as a function of leaf height, as estimated by the binomial GLM, can be visualised by predicting for a grid of values over the observed range of leaf heights. An approximate 95% point-wise confidence interval can also be created for the fitted function. In this case, we should create the confidence interval on the scale of the linear predictor where we assume things behave in a more Gaussian-like manner, and then backtransform the calculated interval on to the probability scale using the invers of the link function. The code below shows a general solution for this, where the inverse link function is obtained from the <code>family()</code> object contained within the fitted GLM object
</p>
<figure>
<pre><code data-lang="r"><span>ilink</span> <span>&lt;-</span> <span>family</span><span>(</span><span>m</span><span>)</span><span>$</span><span>linkinv</span>
<span>pd</span> <span>&lt;-</span> <span>with</span><span>(</span><span>darl</span><span>,</span>
           <span>data.frame</span><span>(</span><span>leafHeight</span> <span>=</span> <span>seq</span><span>(</span><span>min</span><span>(</span><span>leafHeight</span><span>),</span> <span>max</span><span>(</span><span>leafHeight</span><span>),</span>
                                       <span>length</span> <span>=</span> <span>100</span><span>)))</span>
<span>pd</span> <span>&lt;-</span> <span>cbind</span><span>(</span><span>pd</span><span>,</span> <span>predict</span><span>(</span><span>m</span><span>,</span> <span>pd</span><span>,</span> <span>type</span> <span>=</span> <span>&quot;link&quot;</span><span>,</span> <span>se.fit</span> <span>=</span> <span>TRUE</span><span>)[</span><span>1</span><span>:</span><span>2</span><span>])</span>
<span>pd</span> <span>&lt;-</span> <span>transform</span><span>(</span><span>pd</span><span>,</span> <span>Fitted</span> <span>=</span> <span>ilink</span><span>(</span><span>fit</span><span>),</span> <span>Upper</span> <span>=</span> <span>ilink</span><span>(</span><span>fit</span> <span>+</span> <span>(</span><span>2</span> <span>*</span> <span>se.fit</span><span>)),</span>
                <span>Lower</span> <span>=</span> <span>ilink</span><span>(</span><span>fit</span> <span>-</span> <span>(</span><span>2</span> <span>*</span> <span>se.fit</span><span>)))</span>

<span>ggplot</span><span>(</span><span>darl</span><span>,</span> <span>aes</span><span>(</span><span>x</span> <span>=</span> <span>leafHeight</span><span>,</span> <span>y</span> <span>=</span> <span>as.numeric</span><span>(</span><span>visited</span><span>)))</span> <span>+</span>
    <span>geom_ribbon</span><span>(</span><span>data</span> <span>=</span> <span>pd</span><span>,</span> <span>aes</span><span>(</span><span>ymin</span> <span>=</span> <span>Lower</span><span>,</span> <span>ymax</span> <span>=</span> <span>Upper</span><span>,</span> <span>x</span> <span>=</span> <span>leafHeight</span><span>),</span>
                <span>fill</span> <span>=</span> <span>&quot;steelblue2&quot;</span><span>,</span> <span>alpha</span> <span>=</span> <span>0.2</span><span>,</span> <span>inherit.aes</span> <span>=</span> <span>FALSE</span><span>)</span> <span>+</span>
    <span>geom_line</span><span>(</span><span>data</span> <span>=</span> <span>pd</span><span>,</span> <span>aes</span><span>(</span><span>y</span> <span>=</span> <span>Fitted</span><span>,</span> <span>x</span> <span>=</span> <span>leafHeight</span><span>))</span> <span>+</span>
    <span>geom_point</span><span>()</span> <span>+</span>
    <span>labs</span><span>(</span><span>y</span> <span>=</span> <span>&quot;Probability of visitation&quot;</span><span>,</span> <span>x</span> <span>=</span> <span>xlab</span><span>)</span></code></pre>
</figure>
<figure>
<img alt="Estimated probability of visitation plus pointwise 95% confidence interval." src="https://i1.wp.com/www.fromthebottomoftheheap.net/assets/img/posts/glm-prediction-intervals-i-fitted-function-and-ci-1.png?w=456" data-recalc-dims="1">
<figcaption>
Estimated probability of visitation plus pointwise 95% confidence interval.<br>
</figcaption>
</figure>
<p>
So far, so standard; the confidence interval is just that, a Wald confidence interval on the fitted function based on the standard errors of the estimates of the model coefficients. It is not a prediction interval, however.
</p>
<p>
The fitted model can be interpreted as describing the binomial distribution for any given value of <code>leafHeight</code>. The binomial distribution is specified by two parameters; <em>n</em> the number of trials (specified via argument <code>size</code> in R’s <code>dbinom()</code> and related functions), and <em>p</em> the probability of success. In the <em>Darlingtonia</em> example, <em>n</em> is 1 because each leaf was the result of 1 trial; was the leaf visited or not during the experiment? <em>p</em> is given by <span>(g()^{-1} = g(_0 + _1 )^{-1})</span>, where <span>(g)</span> is the logit link function and <span>(g^{-1})</span> is its inverse. In other words, the probability parameter of the binomial distribution is a function of <code>leafHeight</code>.
</p>
<p>
To create a prediction interval for a value of <code>leafHeight</code>, we could look at the probability quantiles of the binomial distribution with <code>size = 1</code> and <code>prob = Fitted[leafHeight]</code>. For example, for the minimum and maximum observed leaf heights the extreme 2.5% and 97.5% probability quantiles are
</p>
<figure>
<pre><code data-lang="r"><span>with</span><span>(</span><span>pd</span><span>,</span> <span>qbinom</span><span>(</span><span>c</span><span>(</span><span>0.025</span><span>,</span> <span>0.975</span><span>),</span> <span>size</span> <span>=</span> <span>1</span><span>,</span> <span>prob</span> <span>=</span> <span>head</span><span>(</span><span>Fitted</span><span>,</span> <span>1L</span><span>)))</span>
<span>with</span><span>(</span><span>pd</span><span>,</span> <span>qbinom</span><span>(</span><span>c</span><span>(</span><span>0.025</span><span>,</span> <span>0.975</span><span>),</span> <span>size</span> <span>=</span> <span>1</span><span>,</span> <span>prob</span> <span>=</span> <span>tail</span><span>(</span><span>Fitted</span><span>,</span> <span>1L</span><span>)))</span></code></pre>
</figure>
<figure>
<pre><code data-lang="text">[1] 0 0
[1] 0 1</code></pre>
</figure>
<p>
In the first instance, for the minimum observed leaf height, the prediction interval is 0. Yes, just 0. For the maximum observed leaf height the 95% prediction interval is 0–1. Neither of these is very useful; one isn’t even an interval in the usual sense of the word, and the other is so wide as to encompass both 0 and 1, which is no more information than we had before we started the whole exercise — a leaf can only be visited or not.
</p>
<p>
But this isn’t quite what we want; we’ve only explore the quantiles of the distributions conditional upon the estimated probability. A real prediction interval would account for the uncertainty in this estimate. For that, we need the upper and lower confidence limits for the estimated probability.
</p>
<figure>
<pre><code data-lang="r"><span>with</span><span>(</span><span>pd</span><span>,</span> <span>qbinom</span><span>(</span><span>c</span><span>(</span><span>0.025</span><span>,</span> <span>0.975</span><span>),</span> <span>size</span> <span>=</span> <span>1</span><span>,</span> <span>prob</span> <span>=</span> <span>c</span><span>(</span><span>head</span><span>(</span><span>Lower</span><span>,</span> <span>1L</span><span>),</span> <span>head</span><span>(</span><span>Upper</span><span>,</span> <span>1L</span><span>))))</span>
<span>with</span><span>(</span><span>pd</span><span>,</span> <span>qbinom</span><span>(</span><span>c</span><span>(</span><span>0.025</span><span>,</span> <span>0.975</span><span>),</span> <span>size</span> <span>=</span> <span>1</span><span>,</span> <span>prob</span> <span>=</span> <span>c</span><span>(</span><span>tail</span><span>(</span><span>Lower</span><span>,</span> <span>1L</span><span>),</span> <span>tail</span><span>(</span><span>Upper</span><span>,</span> <span>1L</span><span>))))</span></code></pre>
</figure>
<figure>
<pre><code data-lang="text">[1] 0 1
[1] 0 1</code></pre>
</figure>
<p>
I think we can all agree that these intervals aren’t really that useful…
</p>
<p>
Another way to use the fitted model is via what it says about the posterior density of the two possible predicted values, visited or unvisited. This can be computed using <code>dbinom()</code> using the code below, again for the minimum and maximum observed leaf heights
</p>
<figure>
<pre><code data-lang="r"><span>db</span> <span>&lt;-</span> <span>with</span><span>(</span><span>pd</span><span>,</span> <span>matrix</span><span>(</span><span>dbinom</span><span>(</span><span>x</span> <span>=</span> <span>rep</span><span>(</span><span>c</span><span>(</span><span>0</span><span>,</span><span>1</span><span>),</span> <span>each</span> <span>=</span> <span>2</span><span>),</span> <span>size</span> <span>=</span> <span>1</span><span>,</span>
                             <span>prob</span> <span>=</span> <span>Fitted</span><span>[</span><span>c</span><span>(</span><span>1</span><span>,</span> <span>100</span><span>)]),</span>
                      <span>ncol</span> <span>=</span> <span>2</span><span>))</span>
<span>colnames</span><span>(</span><span>db</span><span>)</span> <span>&lt;-</span> <span>c</span><span>(</span><span>&quot;NotVisited&quot;</span><span>,</span> <span>&quot;Visited&quot;</span><span>)</span>
<span>rownames</span><span>(</span><span>db</span><span>)</span> <span>&lt;-</span> <span>with</span><span>(</span><span>pd</span><span>,</span> <span>paste</span><span>(</span><span>&quot;leafHeight =&quot;</span><span>,</span> <span>range</span><span>(</span><span>leafHeight</span><span>)))</span>
<span>round</span><span>(</span><span>db</span><span>,</span> <span>4</span><span>)</span></code></pre>
</figure>
<figure>
<pre><code data-lang="text">                NotVisited Visited
leafHeight = 14     0.9966  0.0034
leafHeight = 84     0.0831  0.9169</code></pre>
</figure>
<p>
We see almost all the probability density on the unvisited option for leaves 14cm in height (which is also why the 95% interval we calculated earlier was all on unvisted (0), we’d need to go beyond a 99.7% interval to get the visited alernative (1) included in the interval). For leaves of 84cm, most of the density is on the visited outcome, but with approximately 8% on the unvisited outcome.
</p>
<p>
However, these values are exactly what we get if we just take the fitted probabilities for these leaf heights, which are given by the solid line in the plot we made earlier
</p>
<figure>
<pre><code data-lang="r"><span>with</span><span>(</span><span>pd</span><span>,</span> <span>Fitted</span><span>[</span><span>c</span><span>(</span><span>1</span><span>,</span> <span>100</span><span>)])</span></code></pre>
</figure>
<figure>
<pre><code data-lang="text">[1] 0.003410958 0.916879065</code></pre>
</figure>
<p>
These values are for the visited outcome, but subtract them from 1 and you have the values for the unvisited outcome
</p>
<figure>
<pre><code data-lang="r"><span>with</span><span>(</span><span>pd</span><span>,</span> <span>1</span> <span>-</span> <span>Fitted</span><span>[</span><span>c</span><span>(</span><span>1</span><span>,</span> <span>100</span><span>)])</span></code></pre>
</figure>
<figure>
<pre><code data-lang="text">[1] 0.99658904 0.08312093</code></pre>
</figure>
<p>
As before, this ignores the uncertainty in the estimated probability of visitation. The densities incorporating this uncertainty are shown in the table below
</p>
<table>
<caption>
Estimated probability of the visited and not-visited outcomes based on the upper (upr) and lower (lwr) 95% interval of the model-estimated probability of visitation for two leaf heights.<br>
</caption>
<thead>
<tr>
<th>
</th>
<th>
Not Visited (lwr)
</th>
<th>
Not Visited (upr)
</th>
<th>
Visited (lwr)
</th>
<th>
Visited (upr)
</th>
</tr>
</thead>
<tbody>
<tr>
<td>
leafHeight = 14
</td>
<td>
0.9999
</td>
<td>
0.9125
</td>
<td>
0.0001
</td>
<td>
0.0875
</td>
</tr>
<tr>
<td>
leafHeight = 84
</td>
<td>
0.4415
</td>
<td>
0.0103
</td>
<td>
0.5585
</td>
<td>
0.9897
</td>
</tr>
</tbody>
</table>
<p>
One more thing we can do with the fitted model is simulate random outcomes from it. Again we do this for the minimum and maximum observed leaf heights, first for the lowest leaf height
</p>
<figure>
<pre><code data-lang="r"><span>nrand</span> <span>&lt;-</span> <span>10000</span>
<span>set.seed</span><span>(</span><span>1</span><span>)</span>
<span>table</span><span>(</span><span>rbinom</span><span>(</span><span>nrand</span><span>,</span> <span>size</span> <span>=</span> <span>1</span><span>,</span> <span>prob</span> <span>=</span> <span>with</span><span>(</span><span>pd</span><span>,</span> <span>Fitted</span><span>[</span><span>1</span><span>])))</span> <span>/</span> <span>nrand</span></code></pre>
</figure>
<figure>
<pre><code data-lang="text">     0      1 
0.9977 0.0023 </code></pre>
</figure>
<p>
and then for the largest observed leaf height
</p>
<figure>
<pre><code data-lang="r"><span>set.seed</span><span>(</span><span>1</span><span>)</span>
<span>table</span><span>(</span><span>rbinom</span><span>(</span><span>nrand</span><span>,</span> <span>size</span> <span>=</span> <span>1</span><span>,</span> <span>prob</span> <span>=</span> <span>with</span><span>(</span><span>pd</span><span>,</span> <span>Fitted</span><span>[</span><span>100</span><span>])))</span> <span>/</span> <span>nrand</span></code></pre>
</figure>
<figure>
<pre><code data-lang="text">     0      1 
0.0867 0.9133 </code></pre>
</figure>
<p>
The numbers should look pretty familiar — they are very close to both the posterior densities returned using <code>dbinom()</code> and the the fitted probabilities we just looked at. In fact, as <code>nrand</code> tends to infinity, the proportions of the two outcomes will also approach those given by <code>dbinom()</code>. As before, though I won’t show it, a complete interval would also include the uncertainty in the estimated probability.
</p>
<p>
In this example, the most useful outputs from the model are all based on the binomial distributions given values of leaf height. The interval given by the extreme 2.5th and 97.5th probability quantiles isn’t of much use at all; for the two values of leaf height we looked at the interval either wasn’t an interval or it told us no more information than we already possessed, that leaves either were or were not visited.
</p>
<p>
That said, this binomial GLM example is pretty extreme; the observed data only take values <em>0</em> or <em>1</em> and nothing else. However, this has been a useful exercise to think about what the fitted model represents.
</p>
<p>
In the second part of this post I’ll look at a model for a count response, which will start to look a little more interval-like than the one here.
</p>
<div>
<h3>
References<br>
</h3>
<div>
<p>
Dixon, P. M., Ellison, A. M., and Gotelli, N. J. (2005). Improving the precision of estimates of the frequency of rare events. <em>Ecology</em> 86, 1114–1123. doi:<a target="_blank" rel="nofollow" href="http://doi.org/10.1890/04-0601">http://doi.org/10.1890/04-0601</a>.
</p>
</div>
<div>
<p>
Gotelli, N. J., and Ellison, A. M. (2013). <em>A primer of ecological statistics</em>. second. Sinauer Associates Inc.
</p>
</div>
</div>
<p>
<div>
<div>To <strong>leave a comment</strong> for the author, please follow the link and comment on their blog: <strong><a href="http://www.fromthebottomoftheheap.net/2017/05/01/glm-prediction-intervals-i/"> From the Bottom of the Heap - R</a></strong>.</div>
<hr>
<a rel="nofollow" href="https://www.r-bloggers.com/">R-bloggers.com</a> offers <strong><a rel="nofollow" href="https://feedburner.google.com/fb/a/mailverify?uri=RBloggers">daily e-mail updates</a></strong> about <a title="The R Project for Statistical Computing" rel="nofollow" href="https://www.r-project.org/">R</a> news and <a title="R tutorials" rel="nofollow" href="https://www.r-bloggers.com/search/tutorial">tutorials</a> on topics such as: <a title="Data science" rel="nofollow" href="https://www.r-bloggers.com/search/data%20science">Data science</a>, <a title="Big Data" rel="nofollow" href="https://www.r-bloggers.com/search/Big%20Data">Big Data, <a title="R jobs" rel="nofollow" href="https://www.r-users.com/">R jobs</a>, visualization (<a title="ggplot and ggplot2 tutorials" rel="nofollow" href="https://www.r-bloggers.com/search/ggplot2">ggplot2</a>, <a title="Boxplots using lattice and ggplot2 tutorials" rel="nofollow" href="https://www.r-bloggers.com/search/boxplot">Boxplots</a>, <a title="Maps and gis" rel="nofollow" href="https://www.r-bloggers.com/search/map">maps</a>, <a title="Animation in R" rel="nofollow" href="https://www.r-bloggers.com/search/animation">animation</a>), programming (<a title="RStudio IDE for R" rel="nofollow" href="https://www.r-bloggers.com/search/RStudio">RStudio</a>, <a title="Sweave and literate programming" rel="nofollow" href="https://www.r-bloggers.com/search/sweave">Sweave</a>, <a title="LaTeX in R" rel="nofollow" href="https://www.r-bloggers.com/search/LaTeX">LaTeX</a>, <a title="SQL and databases" rel="nofollow" href="https://www.r-bloggers.com/search/SQL">SQL</a>, <a title="Eclipse IDE for R" rel="nofollow" href="https://www.r-bloggers.com/search/eclipse">Eclipse</a>, <a title="git and github, Version Control System" rel="nofollow" href="https://www.r-bloggers.com/search/git">git</a>, <a title="Large data in R using Hadoop" rel="nofollow" href="https://www.r-bloggers.com/search/hadoop">hadoop</a>, <a title="Web Scraping of google, facebook, yahoo, twitter and more using R" rel="nofollow" href="https://www.r-bloggers.com/search/Web+Scraping">Web Scraping</a>) statistics (<a title="Regressions and ANOVA analysis tutorials" rel="nofollow" href="https://www.r-bloggers.com/search/regression">regression</a>, <a title="principal component analysis tutorial" rel="nofollow" href="https://www.r-bloggers.com/search/PCA">PCA</a>, <a title="Time series" rel="nofollow" href="https://www.r-bloggers.com/search/time+series">time series</a>, <a title="finance trading" rel="nofollow" href="https://www.r-bloggers.com/search/trading">trading</a>) and more...
<img height="1" alt="" width="1" src="http://feeds.feedburner.com/~r/RBloggers/~4/bL6XVQuBJMs"></a></div>