title: How to split data into training/testing sets using sample function
body: <p>I've just started using R and I'm not sure how to incorporate my dataset with the following sample code: </p>
  
  <pre><code>sample(x, size, replace = FALSE, prob = NULL)
  </code></pre>
  
  <p>I have a dataset that I need to put into a training (75%) and testing (25%) set.
  I'm not sure what information I'm supposed to put into the x and size?
  Is x the dataset file, and size how many samples I have?  </p>