readLines("yourfile.r", n = 5) # if text, you'll see code Use:
dput(data, file="reconstructed.R")
(if it contains a function)