IRIS Toolbox Reference Manual

## str2dat

Convert strings to IRIS serial date numbers

#### Syntax

    Dat = str2dat(S,...)

#### Input arguments

- `S` [ char | cellstr ] - Strings representing dates.

#### Output arguments

- `Dat` [ numeric ] - IRIS serial date numbers.

#### Options

- `'freq='` [ `1` | `2` | `4` | `6` | `12` | `52` | `365` | empty ] - Enforce frequency.

See help on `dat2str` for other options available.

#### Description

#### Example

    d = str2dat('04-2010','dateFormat=','MM-YYYY');
    dat2str(d)
    ans =
       '2010M04'

    d = str2dat('04-2010','dateFormat=','MM-YYYY','freq=',4);
    dat2str(d)
    ans =
       '2010Q2'

IRIS Toolbox. Copyright © 2007—2013 Jaromir Benes.