def test_get_matchup(): adj = { 'matchup': { 'batter': [{ 'value': 'Freddie Freeman', 'use_full_sample': False }] } } assert matchups.get_matchup({"use_full_sample": False}, adj)
def test_get_matchup_empty(): data = { 'matchup': { 'pitcher': [{ 'value': 'Babe Ruth', 'use_full_data': False }] } } assert matchups.get_matchup(False, data)
def test_get_matchup(): data = { 'matchup': { 'batter': [{ 'value': ['Freddie Freeman', 'Yasiel Puig'], 'use_full_data': False }] } } assert matchups.get_matchup(False, data)
def run(**kwargs): result = matchups.get_matchup(kwargs["use_full_data"], kwargs["user_mods"]) return result
def run_model(meta_param_dict, adjustment): return matchups.get_matchup(meta_param_dict, adjustment)