title: Passing a vector or dataframe column string date convert to Date format
body: <p>I have loaded data into a .csv within Julia. </p>
  
  <p>I wish to convert my string Date to Date format: </p>
  
  <pre><code>julia&gt; head(df)
  6×7 DataFrames.DataFrame
  │ Row │ Date       │ Open    │ High    │ Low     │ Close   │ Adj_Close │ Volume  │
  ├─────┼────────────┼─────────┼─────────┼─────────┼─────────┼───────────┼─────────┤
  │ 1   │ 1993-01-29 │ 43.9687 │ 43.9687 │ 43.75   │ 43.9375 │ 27.6073   │ 1003200 │
  │ 2   │ 1993-02-01 │ 43.9687 │ 44.25   │ 43.9687 │ 44.25   │ 27.8036   │ 480500  │
  │ 3   │ 1993-02-02 │ 44.2187 │ 44.375  │ 44.125  │ 44.3437 │ 27.8625   │ 201300  │
  │ 4   │ 1993-02-03 │ 44.4062 │ 44.8437 │ 44.375  │ 44.8125 │ 28.1571   │ 529400  │
  │ 5   │ 1993-02-04 │ 44.9687 │ 45.0937 │ 44.4687 │ 45.0    │ 28.2749   │ 531500  │
  │ 6   │ 1993-02-05 │ 44.9687 │ 45.0625 │ 44.7187 │ 44.9687 │ 28.2552   │ 492100  │
  </code></pre>
  
  <p>The type is: </p>
  
  <pre><code>julia&gt; showcols(df)
  6258×7 DataFrames.DataFrame
  │ Col # │ Name      │ Eltype                           │ Missing │ Values                    │
  ├───────┼───────────┼──────────────────────────────────┼─────────┼───────────────────────────┤
  │ 1     │ Date      │ Union{Missings.Missing, String}  │ 0       │ 1993-01-29  …  2017-12-01 │
  │ 2     │ Open      │ Union{Float64, Missings.Missing} │ 0       │ 43.9687  …  264.76        │
  │ 3     │ High      │ Union{Float64, Missings.Missing} │ 0       │ 43.9687  …  265.31        │
  │ 4     │ Low       │ Union{Float64, Missings.Missing} │ 0       │ 43.75  …  260.76          │
  │ 5     │ Close     │ Union{Float64, Missings.Missing} │ 0       │ 43.9375  …  264.46        │
  │ 6     │ Adj_Close │ Union{Float64, Missings.Missing} │ 0       │ 27.6073  …  264.46        │
  │ 7     │ Volume    │ Union{Int64, Missings.Missing}   │ 0       │ 1003200  …  159947700     │
  </code></pre>
  
  <p>Right now the Date is a string. </p>
  
  <p>So wish to convert the column a Date format. </p>
  
  <p>trying: </p>
  
  <pre><code>df[:Date, DateFormat("yyyy-mm-dd")]
  </code></pre>
  
  <p>and </p>
  
  <pre><code>df[df[:Date] = DateFormat("yyyy-mm-dd")]
  </code></pre>
  
  <p>with error: </p>
  
  <p>MethodError: Cannot <code>convert</code> an object of type DateFormat{Symbol("yyyy-mm-dd"),Tuple{Base.Dates.DatePart{'y'},Base.Dates.Delim{Char,1},Base.Dates.DatePart{'m'},Base.Dates.Delim{Char,1},Base.Dates.DatePart{'d'}}} 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.
  in setindex! at DataFrames\src\dataframe\dataframe.jl:376
  in fill! at base\multidimensional.jl:841
  REPL</p>
  
  <p>encase my syntax is wrong I make a vector x from the date column: </p>
  
  <pre><code>x = df[:Date]
  
  Date(x, "yyyy-mm-dd")
  </code></pre>
  
  <p>MethodError: Cannot <code>convert</code> an object of type Array{Union{Missings.Missing, String},1} to an object of type Int64
  REPL</p>
  
  <p>This is easy with R but Julia can not find that great of information, any assistance appreciated. </p>
  
  <p>I am also following this link: </p>
  
  <p><a href="https://docs.julialang.org/en/release-0.4/manual/dates/" rel="nofollow noreferrer">https://docs.julialang.org/en/release-0.4/manual/dates/</a></p>
  
  <p>Here is an example: </p>
  
  <pre><code>julia&gt; df = Dates.DateFormat("y-m-d");
  
  julia&gt; dt = Date("2015-01-01",df)
  2015-01-01
  
  julia&gt; dt2 = Date("2015-01-02",df)
  2015-01-02
  </code></pre>
  
  <p>Why cant I pass a vector or data frame column through this??</p>
  
  <p><strong>Update:</strong></p>
  
  <p>This works when I pass one element from the vector: </p>
  
  <pre><code>julia&gt; Date(x[1], Dates.DateFormat("yyyy-mm-dd"))
  1993-01-29
  </code></pre>
  
  <p>I just want to convert every element to this format and store in the data frame</p>