title: dataframe create new column of integer julia
body: <p>I am trying to add a new column Y to a dataframe of type <code>Float64</code> using another column Z of integer and an array X of type <code>Array{Float64,1}</code>. </p>
  
  <p>When I run the command: </p>
  
  <pre><code>df[:Y] = map(z-&gt;X[z],df[:Z])
  </code></pre>
  
  <p>I get that that type of <code>df[:X]</code> is <code>Any</code>. </p>
  
  <p>How can I change the type of <code>df[:Y]</code> to Float?</p>
  
  <p>Example:</p>
  
  <pre><code>df = DataFrame( Z  = @data([1, 2, 3, 4, 5]) ) 
  X = [1.1 2.2 3.3 4.4 5.5]
  df[:Y] = map(z-&gt;X[z],df[:Z])
  </code></pre>
  
  <p>then <code>typeof(df[:Y])</code> returns <code>DataArrays.DataArray{Any,1}</code>.</p>