metrica
metrica copied to clipboard
function to compare two models
can create a function to assess how two different models compare to each other in predicting an outcome. For this, would need to have a df with at least 3 columns: obs, pred1, pred2. Then the function returns a df with columns metricname, metricvalue, pred1, pred2. These results could then be used as inputs into 2 other functions: one that calculates a final count of how many metrics were optimized for each of the 2 models, and other that plots all metrics for each model.