title: Trying to split data into train, test and validation sets (in chronological order)
body: <p>I have a data set:</p>
  
  <pre><code>library(quantmod)
  getSymbols('GOOG', from = "2010-05-01", to = "2017-05-01", src = "yahoo")
  </code></pre>
  
  <p>I am trying to split this data into train (nrow 1: to nrow 60% of the data), test (nrow 60% of the data to nrow 80% of the data) and finally validate (nrow 80% of the data to nrow 100% of the data).</p>
  
  <p>I have the following;</p>
  
  <pre><code>library(caTools)
  set.seed(123)
  split &lt;- sample.split(GOOG[Close], SplitRatio = 0.60)
  train = subset(GOOG, split == TRUE)
  nottrain = subset(GOOG, split == FALSE)
  </code></pre>
  
  <p>I am stuck here, I have been trying to split the "nottrain" data set into two parts with little luck.</p>
  
  <p>I also believe that the data set gets split randomly (correct me if I am wrong). I am trying to split it as described above.</p>
  
  <p>Any pointers in the right direction would be greatly appreciated.</p>