title: Sweave, include sourced R-Function files
body: <p>I have an Rjob writen in file a.R which calls functions writen in file b.R, and a snw file c.snw. I call c.snw via "R CMD c.snw".</p>
  
  <p>I am looking for a possibilty to only include a.R via \SweaveInput{a.R} into c.snw, but the code of the functions called from a.R should also be written in the tex file. This implies that Sweave traces all source() commands in the included main R file (here a.R).</p>
  
  <p>Can anyone suggest how to do this?</p>