r - R将数据文件从ftp导入数据框
问题描述
如何将数据文件从 ftp 导入 data.frame?
我用:
userpwd <- "user:pw"
h <- curl::new_handle()
curl::handle_setopt(
handle = h,
httpauth = 1,
userpwd = userpwd
)
resp <- curl::curl_fetch_disk("ftp://xxx/testfolder/", "test.csv", handle = h)
但是现在该怎么办?如何将我的测试文件夹中的数据文件从 FTP 带到 R 对象,例如。在数据框中?以及如何从 testfolder 中选择特定的数据文件?
解决方案
推荐阅读
- tcp - TCP 套接字接受的数据是否会过期?
- c++ - GCC 未能报告格式错误的 constexpr lambda 调用
- python-3.x - 在 pyplot/matplotlib 图上没有得到图例和网格
- python - Snake Game IndexError:列表索引超出范围
- react-native - 如何在 React Native 中修复这些漏洞
- here-api - 无法在浏览器上呈现 Here 地图
- java - 在 Cucumber 测试中无法关闭 CamelContext
- powershell - 如果 Pester 测试失败,我如何“不稳定”构建 Jenkins 管道?
- c - 如何在c中添加多个带空格的字符串?
- mysql - 如何使用 ALTER 命令将具有 int 数据类型的列添加到 SQL 中的表中?