func_code | R Documentation |
Produces (simple) R code calling function named "func" with args in list "argv", prepending with source() call to directories in the vector "sources" if specified.
NOTE: args in ... can be lists or vectors consisting of numerical values or characters. Lists can have named fields. These will be assigned in a "hard coded" way in the Rcode, so these should be ideally scalars or pretty short vectors / lists.
For code to run properly, the names of "argv" must correspond to argument names of "func", or if the list has unnamed fields then they must be ordered in the order of the function args.
Useful for dumping tmp code files for farming when there are many arguments being passed
func_code(func, sources = c(), ...)
func |
function to call |
sources |
files to source |
... |
additional arguments to function which should contain numerical or character vectors or lists of such vectors |
character data of source file containing call to function with arguments hard coded
Marcin Imielinski
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.