title: Error in running sfLapply in R
body: <p>My piece of code looks like:</p>
  
  <pre><code>x&lt;- c(1,2,3,4,5)
  
  library(snowfall)
  
  f1&lt;- function(a,list){
    f2&lt;-function(b,num){ return(abs(num-b))}
  
    l1&lt;-sfLapply(list, f2, num=a)
    l1&lt;-sum(unlist(l1))
    return(l1)
  }
  
  sfInit(parallel=TRUE,cpus=4)
  l2&lt;-(sfLapply(x, f1, list=x))
  sfStop()
  l2
  </code></pre>
  
  <p>when I run the last four lines, it gives an error:</p>
  
  <pre><code>l2&lt;-(sfLapply(x, f1, list=x))
  Error in checkForRemoteErrors(val) : 
    4 nodes produced errors; first error: could not find function "sfLapply"
  </code></pre>
  
  <p>When I switch to sequential processing, using lapply, it runs perfectly.</p>
  
  <pre><code>&gt; l2&lt;-(lapply(x, f1, list=x))
  &gt; l2
  [[1]]
  [1] 10
  
  [[2]]
  [1] 7
  
  [[3]]
  [1] 6
  
  [[4]]
  [1] 7
  
  [[5]]
  [1] 10
  </code></pre>
  
  <p>Why is sfLapply throwing an error?</p>