Write data file for OpenBUGS.
bugsData(data, fileName = file.path(tempdir(), "data.txt"),
format="E", digits = 5)Either a named list (names corresponding to variable names in the model file) of the data for the OpenBUGS model, or a vector or list of the names of the data objects used by the model
The filename, defaults to data.txt in the temporary directory of the current R session
String to pass to
formatC which controls formatting of numbers. The default "E" formats all numbers in
scientific notation. The alternative "fg" uses a standard format,
which is more readable but less safe for extreme numbers.
Number of significant digits used for OpenBUGS input,
see formatC. This may need to be adjusted from the
default of 5, for example when writing large integers.
Invisibly returns the fileName.