readBIN2R: Import Risoe BIN-file into R
Description
Import a *.bin or a *.binx file produced by a Risoe DA15 and DA20
TL/OSL reader into R.Usage
readBIN2R(file, show.raw.values = FALSE, n.records, show.record.number = FALSE,
txtProgressBar = TRUE, forced.VersionNumber)
Arguments
file
character (required): bin-file name (including path), e.g.
[WIN]: readBIN2R("C:/Desktop/test.bin")
,
[MAC/LINUX]: readBIN2R("/User/test/Desktop/test.bin")
show.raw.values
logical (with default): shows raw values from BIN file for
LTYPE
, DTYPE
and LIGHTSOURCE
without translation in characters. n.records
raw (optional): limits the number of imported records. Can be used in
combination with show.record.number
for debugging purposes, e.g. corrupt BIN files. show.record.number
logical (with default): shows record number of the imported record,
for debugging usage only. forced.VersionNumber
integer (optional): allows to cheat the version number check in the
function by own values for cases where the BIN-file version is not supported.
Note: The usage is at own risk, only supported BIN-file versions have b Value
- Returns an S4 Risoe.BINfileData-class object containing two slots:
- METADATAA data.frame containing all variables stored in the bin-file.
- DATAA list containing a numeric vector of the measured data.
The ID corresponds to the record ID in METADATA.
Function version
0.7 (2014-04-13 14:31:53)Details
The binary data file is parsed byte by byte following the data structure
published in the Appendices of the Analyst manual p. 42.
For the general BIN-file structure, the reader is referred to the Risoe
website: http://www.nutech.dtu.dk/
References
Duller, G., 2007. Analyst. http://www.nutech.dtu.dk/english/~/media/Andre_Universitetsenheder/Nutech/Produkter%20og%20services/Dosimetri/radiation_measurement_instruments/tl_osl_reader/Manuals/analyst_manual_v3_22b.ashxExamples
Run this code##(1) import Risoe BIN-file to R (uncomment for usage)
#FILE <- file.choose()
#temp <- readBIN2R(FILE)
#temp
Run the code above in your browser using DataLab