set.seed(1500)
stream <- DSD_Gaussians(k = 3, d = 2)
writer <- DST_WriteStream(file = "data.txt", info = TRUE)
update(writer, stream, n = 2)
readLines("data.txt")
update(writer, stream, n = 3)
readLines("data.txt")
# clean up
close_stream(writer)
file.remove("data.txt")
Run the code above in your browser using DataLab