as_nanoarrow_schema: Convert an object to a nanoarrow schema

View source: R/schema.R

as_nanoarrow_schemaR Documentation

Convert an object to a nanoarrow schema

Description

In nanoarrow a 'schema' refers to a ⁠struct ArrowSchema⁠ as defined in the Arrow C Data interface. This data structure can be used to represent an arrow::schema(), an arrow::field(), or an arrow::DataType. Note that in nanoarrow, an arrow::schema() and a non-nullable arrow::struct() are represented identically.

Usage

as_nanoarrow_schema(x, ...)

infer_nanoarrow_schema(x, ...)

nanoarrow_schema_parse(x, recursive = FALSE)

nanoarrow_schema_modify(x, new_values, validate = TRUE)

Arguments

x

An object to convert to a schema

...

Passed to S3 methods

recursive

Use TRUE to include a children member when parsing schemas.

new_values

New schema component to assign

validate

Use FALSE to skip schema validation

Value

An object of class 'nanoarrow_schema'

Examples

infer_nanoarrow_schema(integer())
infer_nanoarrow_schema(data.frame(x = integer()))


nanoarrow documentation built on Sept. 30, 2023, 1:06 a.m.