# pydicom.valuerep.DA

class pydicom.valuerep.DA(*args: Any, **kwargs: Any)

  Store value for an element with VR DA as `datetime.date`.

  Note that the `datetime.date` base class is immutable.

  __init__(*args: Any, **kwargs: Any) → None

    Create a new DA element value.

  Methods

  `__init__`(*args, **kwargs) | Create a new DA element value.
  `ctime`() | Return ctime() style string.
  `fromisocalendar` | int, int, int -> Construct a date from the ISO year, week number and weekday.
  `fromisoformat`(object, /) | str -> Construct a date from a string in ISO 8601 format.
  `fromordinal` | int -> date corresponding to a proleptic Gregorian ordinal.
  `fromtimestamp`(timestamp, /) | Create a date from a POSIX timestamp.
  `isocalendar`() | Return a named tuple containing ISO year, week number, and weekday.
  `isoformat`() | Return string in ISO 8601 format, YYYY-MM-DD.
  `isoweekday`() | Return the day of the week represented by the date.
  `replace` | Return date with new specified fields.
  `strftime` | format -> strftime() style string.
  `strptime` | string, format -> new date parsed from a string (like time.strptime()).
  `timetuple`() | Return time tuple, compatible with time.localtime().
  `today`() | Current date or datetime: same as self.__class__.fromtimestamp(time.time()).
  `toordinal`() | Return proleptic Gregorian ordinal.
  `weekday`() | Return the day of the week represented by the date.

  Attributes

  `day` |
  `max` |
  `min` |
  `month` |
  `resolution` |
  `year` |
  `original_string` |

  ctime()

    Return ctime() style string.

  classmethod fromisocalendar()

    int, int, int -> Construct a date from the ISO year, week number and weekday.

    This is the inverse of the date.isocalendar() function

  classmethod fromisoformat(object, /)

    str -> Construct a date from a string in ISO 8601 format.

  classmethod fromordinal()

    int -> date corresponding to a proleptic Gregorian ordinal.

  classmethod fromtimestamp(timestamp, /)

    Create a date from a POSIX timestamp.

    The timestamp is a number, e.g. created via time.time(), that is interpreted as local time.

  isocalendar()

    Return a named tuple containing ISO year, week number, and weekday.

  isoformat()

    Return string in ISO 8601 format, YYYY-MM-DD.

  isoweekday()

    Return the day of the week represented by the date. Monday == 1 … Sunday == 7

  replace()

    Return date with new specified fields.

  strftime()

    format -> strftime() style string.

  classmethod strptime()

    string, format -> new date parsed from a string (like time.strptime()).

  timetuple()

    Return time tuple, compatible with time.localtime().

  classmethod today()

    Current date or datetime: same as self.__class__.fromtimestamp(time.time()).

  toordinal()

    Return proleptic Gregorian ordinal. January 1 of year 1 is day 1.

  weekday()

    Return the day of the week represented by the date. Monday == 0 … Sunday == 6