我在 R 中有一个数据框,其中包含我想在计算机文件夹中创建的文本文件(MSU870N.wea、MAU870N.tim 等)的名称。我怎样才能在 R 中做到这一点。
像这样?
fn <- c("test1.txt", "test2.txt", "test3.txt")
for(name in fn)
cat("This is a text file's content", file = name)
本文收集自互联网,转载请注明来源。
如有侵权,请联系 [email protected] 删除。
我来说两句