title: Sample.Split in R SplitRatio parameter has to be i [0,1]
body: <p>I am getting the following error:</p>
  
  <blockquote>
    <p>Error in sample.split: 'SplitRatio' parameter has to be i [0, 1] range or [1, length(Y)] range</p>
  </blockquote>
  
  <p>when I try to run the following code:</p>
  
  <pre><code>set.seed(1000)
  library(caTools)
  split = sample.split(letters$isB, SplitRatio = 0.5)
  </code></pre>