跳过内容

Apache Arrow 定义了两种用于进程间通信 (IPC) 的数据序列化格式:“流”格式和“文件”格式(称为 Feather)。write_ipc_stream()write_feather() 分别写入这些格式。

用法

write_ipc_stream(x, sink, ...)

参数

x

data.frameRecordBatchTable

sink

字符串文件路径、连接、URI 或 OutputStream,或文件系统中的路径 (SubTreeFileSystem)

...

传递给 write_feather() 的额外参数。

返回值

x,不可见。

另请参阅

write_feather() 用于写入 IPC 文件。write_to_raw() 用于将数据序列化到缓冲区。RecordBatchWriter 用于更底层的接口。

示例

tf <- tempfile()
on.exit(unlink(tf))
write_ipc_stream(mtcars, tf)