class_docstr: Namespace for string related expressions.
class_docstr_tok: ["Namespace","for","string","related","expressions","."]
docstr: Convert a String column into a Date column.
  
  Parameters
  ----------
  format
      Format to use for conversion. Refer to the `chrono crate documentation
      <https://docs.rs/chrono/latest/chrono/format/strftime/index.html>`_
      for the full specification. Example: `"%Y-%m-%d"`.
      If set to None (default), the format is inferred from the data.
  strict
      Raise an error if any conversion fails.
  exact
      Require an exact format match. If False, allow the format to match anywhere
      in the target string.
  
      .. note::
          Using `exact=False` introduces a performance penalty - cleaning your
          data beforehand will almost certainly be more performant.
  cache
      Use a cache of unique, converted dates to apply the conversion.
  
  Examples
  --------
  >>> s = pl.Series(["2020/01/01", "2020/02/01", "2020/03/01"])
  >>> s.str.to_date()
  shape: (3,)
  Series: '' [date]
  [
          2020-01-01
          2020-02-01
          2020-03-01
  ]
docstr_tok: ["Convert","a","String","column","into","a","Date","column",".","Parameters","--","--","--","--","--","format","Format","to","use","for","conversion",".","Refer","to","the","`","chrono","crate","documentation","<","https",":","\/\/docs.rs\/chrono\/latest\/chrono\/format\/strftime\/index.html",">","`","_","for","the","full","specification",".","Example",":","`","``","%","Y-","%","m-","%","d","''","`",".","If","set","to","None","(","default",")",",","the","format","is","inferred","from","the","data",".","strict","Raise","an","error","if","any","conversion","fails",".","exact","Require","an","exact","format","match",".","If","False",",","allow","the","format","to","match","anywhere","in","the","target","string",".","..","note",":",":","Using","`","exact=False","`","introduces","a","performance","penalty","-","cleaning","your","data","beforehand","will","almost","certainly","be","more","performant",".","cache","Use","a","cache","of","unique",",","converted","dates","to","apply","the","conversion",".","Examples","--","--","--","--",">",">",">","s","=","pl.Series","(","[","``","2020\/01\/01","''",",","``","2020\/02\/01","''",",","``","2020\/03\/01","''","]",")",">",">",">","s.str.to_date","(",")","shape",":","(","3",",",")","Series",":","``","[","date","]","[","2020-01-01","2020-02-01","2020-03-01","]"]
code: def to_date(
      self,
      format: str | None = None,
      *,
      strict: bool = True,
      exact: bool = True,
      cache: bool = True,
  ) -> Expr:
      """
      Convert a String column into a Date column.
  
      Parameters
      ----------
      format
          Format to use for conversion. Refer to the `chrono crate documentation
          <https://docs.rs/chrono/latest/chrono/format/strftime/index.html>`_
          for the full specification. Example: `"%Y-%m-%d"`.
          If set to None (default), the format is inferred from the data.
      strict
          Raise an error if any conversion fails.
      exact
          Require an exact format match. If False, allow the format to match anywhere
          in the target string.
  
          .. note::
              Using `exact=False` introduces a performance penalty - cleaning your
              data beforehand will almost certainly be more performant.
      cache
          Use a cache of unique, converted dates to apply the conversion.
  
      Examples
      --------
      >>> s = pl.Series(["2020/01/01", "2020/02/01", "2020/03/01"])
      >>> s.str.to_date()
      shape: (3,)
      Series: '' [date]
      [
              2020-01-01
              2020-02-01
              2020-03-01
      ]
  
      """
      _validate_format_argument(format)
      return wrap_expr(
          self._pyexpr.str_to_date(format, strict, exact, cache)
      )
  
imports: from __future__ import annotations
  import warnings
  from typing import TYPE_CHECKING
  import polars._reexport
  from polars import functions
  from polars.datatypes import Date, Datetime, Int32, Time, py_type_to_dtype
  from polars.exceptions import ChronoFormatWarning
  from polars.utils._parse_expr_input import parse_as_expression
  from polars.utils._wrap import wrap_expr
  from polars.utils.deprecation import deprecate_renamed_function, deprecate_renamed_parameter, rename_use_earliest_to_ambiguous
  from polars.utils.various import find_stacklevel
label_desc: Use image node_id 2 for calling the ExprStringNameSpace obj's underlying member method code with example usage: obj.to_date(format) and returns: wrap_expr