Reads binary data using the base function readBin
and recasts it into an array of custom dimensions.
loadbin(
filename,
dim,
bytes = 4,
type = "numeric",
signed = FALSE,
endian = "little"
)
Returns an array of dimension dim.
path of the file to be loaded
vector specifying the dimensions of the array
number of bytes per number in the binary file
character vector of length describing the data type: "numeric" (default), "double", "integer", "int", "logical", "complex", "character", "raw"
logical. Only used for integers of sizes 1 and 2, when it determines if the quantity on file should be regarded as a signed or unsigned integer.
endian-type ("big" or "little") of the file
Danail Obreschkow