psse_parse_section

psse_parse_section(warns, records, sections, s, verbose, label, template)

psse_parse_section() - Parses the data from a section of a PSS/E RAW data file.

[DATA, WARNINGS] = PSSE_PARSE_SECTION(WARNINGS, RECORDS, SECTIONS, SIDX, ...
                                        VERBOSE, LABEL, TEMPLATE)
[DATA, WARNINGS] = PSSE_PARSE_SECTION(WARNINGS, RECORDS, SECTIONS, SIDX, ...
                                        VERBOSE, LABEL)
[DATA, WARNINGS] = PSSE_PARSE_SECTION(WARNINGS, RECORDS, SECTIONS, SIDX, ...
                                        VERBOSE)
[DATA, WARNINGS] = PSSE_PARSE_SECTION(WARNINGS, RECORDS, SECTIONS, SIDX)
[DATA, WARNINGS] = PSSE_PARSE_SECTION(WARNINGS, RECORDS, VERBOSE, LABEL, ...
                                        TEMPLATE)
[DATA, WARNINGS] = PSSE_PARSE_SECTION(WARNINGS, RECORDS, VERBOSE, LABEL)
[DATA, WARNINGS] = PSSE_PARSE_SECTION(WARNINGS, RECORDS, VERBOSE)
[DATA, WARNINGS] = PSSE_PARSE_SECTION(WARNINGS, RECORDS)

Inputs:
    WARNINGS :  cell array of strings containing accumulated
                warning messages
    RECORDS :   a cell array of strings returned by PSSE_READ
    SECTIONS :  a struct array returned by PSSE_READ
    SIDX :      (optional) index if the section to be read
                if included, the RECORD indices are taken from
                SECTIONS(SIDX), otherwise use all RECORDS
    VERBOSE :   1 to display progress info, 0 (default) otherwise
    LABEL :     (optional) name for the section, to be compared with
                the section name typically found in the
                END OF <LABEL> DATA comment at the end of each section
    TEMPLATE :  (optional) string of characters indicating how to
                interpret the type of the corresponding column, options
                are as follows:
            d, f or g : integer floating point number to be converted
                via SSCANF with %d, %f or %g, respectively.
            D, F or G : integer floating point number, possibly enclosed
                in single or double quotes, to be converted via
                SSCANF with %d, %f or %g, respectively.
            c or s : character or string, possibly enclosed in single
                or double quotes, which are stripped from the string
        Note:   Data columns in RECORDS that have no valid corresponding
                entry in TEMPLATE (beyond end of TEMPLATE, or a character
                other than those listed, e.g. '.') are returned in DATA.txt
                with no conversion. TEMPLATE entries for which there is
                no corresponding column in RECORDS are returned as NaN and
                empty, respectively, in DATA.num and DATA.txt.

Output:
    DATA :      a struct with two fields:
        num :   matrix containing the numeric data for the section, for
                columns with no numeric data, num contain NaNs.
        txt :   a cell array containing the non-numeric (char/string)
                data for the section, for columns with numeric data,
                txt entries are empty
    WARNINGS :  cell array of strings containing updated accumulated
                warning messages

See also psse2mpc(), psse_parse().