def _parse_csv_row(row):
    """Parse the CSV row, returning variables and values.

    Parameters
    ----------
    row : list of str
        A non-empty line from the CSV data file with starting and ending white
        space stripped out.

    Returns
    -------
    str, list of str or None
        The variable name, and list of variable values. If the line contains
        no variable then returns None.
    """
    # Allowed variables
    variables = ['X_TITLE', 'X_HEADERS', 'X_VALUES', 'X_FORMAT',
                 'Y_TITLE', 'Y_HEADERS', 'Y_VALUES', 'Y_FORMAT',
                 'XY_FORMAT', 'XY_TYPE', 'DESCRIPTION', 'SOURCE']

    if '=' in row[0]:
        split_item = row[0].split('=')
        variable_name = split_item[0]
        variable_values = [split_item[1]]

        if variable_name not in variables:
            raise ValueError('The CSV data file contains an unknown variable.')

        if row[1:]:
            variable_values.extend(row[1:])

        return variable_name, variable_values

    return None, None