代码如下所示:
schema = schema(`Key`=int64(),
Sex = string(),
`Age` = int64(),
`Date of Birth` = date32(),
`Institution` = string(),
`Admission Date` = date32(),
`Discharge Date` = date32(),
`Elderly Home` = string(),
`Paycode` = string())
class(schema)
R返回:
Error in `check_schema()`:
! `schema` must be an object of class 'Schema' not 'list'.
Run `rlang::last_error()` to see where the error occurred.
> class(schema)
[1] "list"
是否可以将列表转换为schema
?
我运行的版本:版本应为Arrow包版本:11.0.0.2.
> arrow::arrow_info()
Arrow package version: 11.0.0.2
Arrow options():
arrow.use_threads FALSE
1条答案
按热度按时间nbysray51#
我不能重现你描述的错误,但是我们可以通过使用
rlang::inject()
将list
对象转换为schema
:关于OP中显示的错误,下面是我看到的:
创建于2023-03-23带有reprex v2.0.2