test_jobs | R Documentation |
performing jobs locally.
test_jobs( work_func, data = NULL, n = NULL, init_func = NULL, global_vars = NULL, packages = c(), files = c(), callback_function = NULL, install_func = NULL )
work_func |
data processing function with prototype
|
data |
data for processing. Must be a numerable list or vector. |
n |
a number of jobs. This parameter must be less than or equal to the length of the data. If not specified, then the number of jobs will be equal to the length of the data. |
init_func |
initialization function with prototype |
global_vars |
a list in the format
|
packages |
a string vector with imported packages names. |
files |
a string vector with the files names that should be available for jobs. |
callback_function |
a function with prototype
|
install_func |
installation function with prototype
|
Like create_jobs, it creates a jobs for the BOINC server but does not submit them. Instead, it runs all jobs locally and generates a report at each step. This function is intended for debugging applications that use RBOINC. Files created by this function are not deleted after its completion.
When errors occur, execution can be stopped with the following messages:
"Archive making error: <
error message>
"
"You must specify 'data' or 'n'."
"The number of tasks must be less or equal than length of data."
a list with states of jobs. This list contains the following fields:
log - Rscript output;
result - computation result.
## Not run: # Function for data processing: fun = function(val) { ... } # Data for processing: data = list(...) # Test jobs locally: res = test_jobs(fun, data) ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.