title: Data inside a function (package creation)
body: <p>If I need to use a data set inside a function (as a lookup table) inside of a package I'm creating do I need to explicitly load the data set inside of the function?</p>
  
  <p>The function and the data set are both part of my package.</p>
  
  <p>Is this the correct way to use that data set inside the function:</p>
  
  <pre><code>foo &lt;- function(x){
      x &lt;- dataset_in_question
  }
  </code></pre>
  
  <p>or is this better:</p>
  
  <pre><code>foo &lt;- function(x){
      x &lt;- data(dataset_in_question)
  }
  </code></pre>
  
  <p>or is there some approach I'm not thinking of that's correct?</p>