r读取文件夹下的所有csv文件_使用R读取压缩文件夹中的csv文件而不解压缩

I have a zipped file named master.zip which contains 2 CSV files inside it: file1.csv and file2.csv

I want to read file1.csv only, something like: read_csv('master/file1.csv'), but without having to unzip master.zip. How can I achieve this with R?

解决方案

You just need to use the native function unz(). Let's assume that master.zip is in your working directory,

# just a list of files inside master.zip

master

# load the first file "file1.csv"

data

sep = ",")

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值