def _parse_field(parsing_scheme, html_data, field, index=<NUM_LIT:0>):
if field == '<STR_LIT>':<EOL><INDENT>return _parse_abbreviation(html_data)<EOL><DEDENT>scheme = parsing_scheme[field]<EOL>items = [i.text() for i in html_data(scheme).items()]<EOL>if len(items) == <NUM_LIT:0>:<EOL><INDENT>return None<EOL><DEDENT>try:<EOL><INDENT>return items[index]<EOL><DEDENT>except IndexError:<EOL><INDENT>return None<EOL><DEDENT>
Parse an HTML table to find the requested field's value.

All of the values are passed in an HTML table row instead of as individual
items. The values need to be parsed by matching the requested attribute
with a parsing scheme that sports-reference uses to differentiate stats.
This function returns a single value for the given attribute.

Parameters
----------
parsing_scheme : dict
    A dictionary of the parsing scheme to be used to find the desired
    field. The key corresponds to the attribute name to parse, and the
    value is a PyQuery-readable parsing scheme as a string (such as
    'td[data-stat="wins"]').
html_data : string
    A string containing all of the rows of stats for a given team. If
    multiple tables are being referenced, this will be comprised of
    multiple rows in a single string.
field : string
    The name of the attribute to match. Field must be a key in
    parsing_scheme.
index : int (optional)
    An optional index if multiple fields have the same attribute name. For
    example, 'HR' may stand for the number of home runs a baseball team has
    hit, or the number of home runs a pitcher has given up. The index
    aligns with the order in which the attributes are recevied in the
    html_data parameter.

Returns
-------
string
    The value at the specified index for the requested field. If no value
    could be found, returns None.