add time and size output in the file for R