JanaJarecki / cognitivemodels

Cognitivemodels is an open-source R library to create, fit, test, and compare computational cognitive models based on machine-learning principles.
25 stars 4 forks source link

Shortfall: no error with non-binary responses #39

Closed FlorianSeitz closed 4 years ago

FlorianSeitz commented 4 years ago

https://github.com/JanaJarecki/cognitivemodels/blob/e890596d7d11745b2f01e24a4cdbecbaff0a28f6/tests/testthat/test_shortfall.R#L182

The shortfall model does not give any error, when non-binary responses are given in the left hand side of the formula. I'm not sure, whether an error or warning would make sense here? Or should we leave this option in case we have aggregate data with repeated measurement (e.g., in 0.6 of all cases participant A chose option X when choosing between X and Y)?

JanaJarecki commented 4 years ago

good point but in the case of the shortfall model the model predicts either utilities or choices, this is intentional because the utility-scale is between -inf and inf