How to add an int column to a DataFrame of strings?
d = DataFrames.DataFrame([["hello", "world"]], [:strs])
d[:num] = [1,2]
gives an error:
MethodError: Cannot
convert
an object of type Int64 to an object of type String
This may have arisen from a call to the constructor String(…),
since type constructors fall back to convert methods.
But this works:
d[:num] = ["a","b"]
I thought columns of DataFrame need not have the same type.