run_template {civis}R Documentation

Run a template script

Description

Run a template script

Usage

run_template(id, arguments, JSONValue = FALSE, ...)

Arguments

id

id of the template script.

arguments

list of arguments to the script.

JSONValue

bool (default FALSE) If true, returns the JSON values instead of the file_ids

...

additional arguments to scripts_post_custom

Value

If JSONValue is FALSE, File ids of any run outputs are returned. If JSONValue is TRUE, JSON values of first JSON run output is returned. If there are no JSON outputs, warning message is printed and nothing is returned If there are more than 1 JSON outputs, warning message is printed and the first JSON output is returned.

See Also

Other script_utils: civis_script(), fetch_output_file_ids(), run_civis()

Examples

## Not run: 
# Try a search for the template id
search_list('template name', type = 'template_script')

# Run the template
run_template(id, arguments = list(arg1 = 1, arg2 = 2), ...)

# Run the template and return JSON value outputs
run_template(id, arguments = list(arg1 = 1, arg2 = 2), JSONValue=TRUE, ...)

## End(Not run)

[Package civis version 3.1.2 Index]