【发布时间】:2015-12-21 09:19:00
【问题描述】:
以下 R 代码将通过命令提示符(windows)执行
# Collect arguments
args <- commandArgs(TRUE)
archivo <- as.character(args[1])
cat(archivo)
喜欢这个
C:\Users\Owner\Desktop>Rscript prueba.r "hola&chao"
问题是命令提示符响应
hola
'chao' is not recognized as an internal or external command,
operable program or batch file.
C:\Users\Owner\Desktop>
我需要 R 接受“&”作为字符并在 cat() 中一起打印
我该怎么办? 谢谢
【问题讨论】: