我想在R中找到fread
的文件。我已经安装了7z
。
我试过
fread(shell(cmd = '7z l test.txt.gz'), shell = 'cmd.exe'))
但是我收到了错误
Error in fread(shell(cmd = paste0("7z x ", "\"", dest, "\""), shell = "cmd.exe")) :
'input' must be a single character string containing a file name, a command, full path to a file, a URL starting 'http[s]://', 'ftp[s]://' or 'file://', or the input data itself
我正在寻找类似的东西:
fread(shell(cmd = 'unzip -cq test.zip', shell = 'cmd.exe'))
答案 0 :(得分:0)
一种解决方法是将 7z.exe
复制到项目文件夹。并尝试:
DT = fread(cmd = '7z e -so "test.zip"')
有些人建议将 7-zip 添加到 Windows PATH 环境变量中。但它对我不起作用。