R --no-save <mergefiles.r
nohup R [options] [< infile] [> outfile]
nohup 后台运行程序
options:
--version 查看R版本;
--slave 只打印R脚本的输出,而不显示脚本具体执行情况;
--vanilla是 --no-save, --no-restore, --no-site-file, --no-init-file 和 --no-environ的综合;
--args 后面是需要传递的参数。
注意:options必须选择--save,--no-save, --vanilla三个中的一个。
比如编辑一个mergefiles.r文件如下:
R --slave --vanilla <mergefiles.r
本文转载自刘峰科学网博客:http://blog.sciencenet.cn/blog-690775-900520.html