I have a DataArray{UTF8String,1} and I have a Dict generated using indexmap 
that should take this UTF8String and return an Int64, however, when I pass 
this through `map`, I get back a DataArray{Any, 1} instead of an 
Array{Int64, 1}

Any idea why and what I can do to fix it?  I'm using Julia 0.3.6 via IJulia

In [165]:
1

typeof(dimensionindexmap)

Out[165]:

Dict{Symbol,Dict{String,Int64}} (constructor with 3 methods)

In [166]:
1

typeof(dimensionindexmap[:geo_cc])

Out[166]:

Dict{String,Int64} (constructor with 3 methods)

In [178]:
1

typeof(results[:geo_cc])

Out[178]:

DataArray{UTF8String,1} (constructor with 1 method)

In [177]:
1

a = results[:geo_cc]

2

typeof(map(x -> get(dimensionindexmap[:geo_cc], x, 1), a))

Out[177]:

DataArray{Any,1} (constructor with 1 method)


Thanks,

Philip

Reply via email to