Luminescence (version 0.9.23)

write_R2BIN: Export Risoe.BINfileData into Risø BIN/BINX-file

Description

Exports a Risoe.BINfileData object in a *.bin or *.binx file that can be opened by the Analyst software or other Risø software.

Usage

write_R2BIN(
  object,
  file,
  version,
  compatibility.mode = FALSE,
  txtProgressBar = TRUE
)

Value

Write a binary file.

Arguments

object

Risoe.BINfileData (required): input object to be stored in a bin file.

file

character (required): file name and path of the output file

  • [WIN]: write_R2BIN(object, "C:/Desktop/test.bin")

  • [MAC/LINUX]: write_R2BIN("/User/test/Desktop/test.bin")

version

character (optional): version number for the output file. If no value is provided the highest version number from the Risoe.BINfileData is taken automatically.

Note: This argument can be used to convert BIN-file versions.

compatibility.mode

logical (with default): this option recalculates the position values if necessary and set the max. value to 48. The old position number is appended as comment (e.g., 'OP: 70). This option accounts for potential compatibility problems with the Analyst software. It further limits the maximum number of points per curve to 9,999. If a curve contains more data the curve data got binned using the smallest possible bin width.

txtProgressBar

logical (with default): enables or disables txtProgressBar.

Function version

0.5.2

How to cite

Kreutzer, S., 2023. write_R2BIN(): Export Risoe.BINfileData into Risø BIN/BINX-file. Function version 0.5.2. In: Kreutzer, S., Burow, C., Dietze, M., Fuchs, M.C., Schmidt, C., Fischer, M., Friedrich, J., Mercier, N., Philippe, A., Riedesel, S., Autzen, M., Mittelstrass, D., Gray, H.J., Galharret, J., 2023. Luminescence: Comprehensive Luminescence Dating Data Analysis. R package version 0.9.23. https://CRAN.R-project.org/package=Luminescence

Author

Sebastian Kreutzer, Institute of Geography, Heidelberg University (Germany) , RLum Developer Team

Details

The structure of the exported binary data follows the data structure published in the Appendices of the Analyst manual p. 42.

If LTYPE, DTYPE and LIGHTSOURCE are not of type character, no transformation into numeric values is done.

References

DTU Nutech, 2016. The Sequence Editor, Users Manual, February, 2016. https://www.fysik.dtu.dk

See Also

read_BIN2R, Risoe.BINfileData, writeBin

Examples

Run this code
##load exampled dataset
file <- system.file("extdata/BINfile_V8.binx", package = "Luminescence")
temp <- read_BIN2R(file)

##create temporary file path
##(for usage replace by own path)
temp_file <- tempfile(pattern = "output", fileext = ".binx")

##export to temporary file path
write_R2BIN(temp, file = temp_file)

Run the code above in your browser using DataLab