temp_dir = tempdir()
if (!dir.exists(temp_dir)) dir.create(temp_dir)
x <- big.matrix(nrow=3, ncol=3, backingfile='flushtest.bin',
descriptorfile='flushtest.desc', backingpath=temp_dir,
type='integer')
x[1,1] <- 0
flush(x)
Run the code above in your browser using DataLab