Dataframe issue with converting to Matrix{Bool}
Closed this issue · 1 comments
khosravipasha commented
It seems in the new version of DataFrames some of the code we have fails intwenty_datasets
function.
The error is
ERROR: MethodError: Cannot `convert` an object of type DataFrames.DataFrame to an object of type Matrix{Bool}
Closest candidates are:
convert(::Type{Array{T, N}}, ::StaticArrays.SizedArray{S, T, N, N, Array{T, N}}) where {S, T, N} at /home/pasha/.julia/packages/StaticArrays/vxjOO/src/SizedArray.jl:120
convert(::Type{Array{T, N}}, ::StaticArrays.SizedArray{S, T, N, M, TData} where {M, TData<:AbstractArray{T, M}}) where {T, S, N} at /home/pasha/.julia/packages/StaticArrays/vxjOO/src/SizedArray.jl:114
convert(::Type{Array{S, N}}, ::PooledArrays.PooledArray{T, R, N, RA} where RA) where {S, T, R, N} at /home/pasha/.julia/packages/PooledArrays/CV8kA/src/PooledArrays.jl:425
...
Stacktrace:
[1] (::LogicCircuits.LoadSave.var"#load#89"{String, String})(type::String)
@ LogicCircuits.LoadSave ~/.julia/dev/LogicCircuits/src/LoadSave/data_loaders.jl:63
[2] twenty_datasets(name::String)
@ LogicCircuits.LoadSave ~/.julia/dev/LogicCircuits/src/LoadSave/data_loaders.jl:65
[3] top-level scope
@ REPL[5]:1
Also might want to add a test for twenty_datasets
khosravipasha commented
can use Tables.matrix(dataframe)
to do this conversion. Already fixed in the code #94