title: lapply() when function returns NULL
body: <p>Is there a method to stop <code>lapply()</code> from returning NULL values for each element of the list when a function doesn't have a <code>return()</code>. </p>
  
  <p>Here's a pretty basic example: </p>
  
  <pre><code>x &lt;- function(x) {
  return(NULL) }
  
  a.list &lt;- list(a=1,b=2,c=3)
  
  lapply(a.list, x)
  </code></pre>
  
  <p>The output is:</p>
  
  <pre><code>$a
  NULL
  
  $b
  NULL
  
  $c
  NULL
  </code></pre>
  
  <p>My goal is to not have that output, at all.</p>
  
  <p>Update: my usage case is as follows. I'm using <code>lapply()</code> to pump out <code>xtable()</code> text and I'm <code>sink()</code>'ing it to an Rnw file. So this NULL output is bugging up my automation. </p>