as_record_batch | R Documentation |
Whereas record_batch()
constructs a RecordBatch from one or more columns,
as_record_batch()
converts a single object to an Arrow RecordBatch.
as_record_batch(x, ..., schema = NULL)
## S3 method for class 'RecordBatch'
as_record_batch(x, ..., schema = NULL)
## S3 method for class 'Table'
as_record_batch(x, ..., schema = NULL)
## S3 method for class 'arrow_dplyr_query'
as_record_batch(x, ...)
## S3 method for class 'data.frame'
as_record_batch(x, ..., schema = NULL)
x |
An object to convert to an Arrow RecordBatch |
... |
Passed to S3 methods |
schema |
a Schema, or |
A RecordBatch
# use as_record_batch() for a single object
as_record_batch(data.frame(col1 = 1, col2 = "two"))
# use record_batch() to create from columns
record_batch(col1 = 1, col2 = "two")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.