def METHOD_NAME(df, encoding):
    try:
        x_values, y_values = GraphBase._get_x_y_values_aggregated(
            df, encoding.x, encoding.y, encoding.y_aggregation
        )
    except ValueError:
        x_values = GraphBase._get_x_values(df, encoding)
        y_values = GraphBase._get_y_values(df, encoding)
    return x_values, y_values