Open thudjx opened 4 years ago
It appears that this issue is because the Arrow
package needs to be updated for changes in CategoricalArrays
. I think the Arrow structure for a CategoricalArray
or a PooledArray
should be DictEncoding
. The code in Arrow
is trying to use getlevels
to, well, get the levels of the CategoricalArray
, whereas now, according to DataAPI, I think it should use levels
. @ExpandingMan Should this issue be transferred to the Arrow
package?
It appears as if https://github.com/ExpandingMan/Arrow.jl/pull/52 already addresses this issue.
I have a
DataFrame
as following:,where the type of
:Species
isCategoricalValue{String,UInt8}
. Now I try to store it in a feather format and an error occurs,Well, let me convert the type of
:Species
:and try to store it again, resulting in another error:
So I try to convert the type into purely
String
:and try again:
And it works!
But I still have a question here. Here my
test_data
is retrieved fromRDataets.jl
and is simple enough to transfer the type of:Species
to a Array ofString
. But what if my data type is complex and I can't do this conversion? Furthermore, I have seen two scenarios that aDataFrame
cannot be written into a .feather file. So what are the general constrains on the types in aDataFrame
for it can applyFeather.write
?Thanks in advance.