NetLogo/models

Simple Economy: put back max/min-n-of in plotting code

Closed this issue · 5 comments

67e4ec8 replaced the use of max-n-of and min-n-of by alternative code using sort to get around the fact that max-n-of and min-n-of are not yet available in NetLogo Web. Once they are, however, we should revert that change because the original code was simpler and clearer.

Maybe that will also be the occasion to replace hard coded numbers 50 and 250 with actual percentage calculations, making the plot more robust in case someone changes the population (there is no slider for that but a user could easily modify the code).

Just checking, is this still 5.2.1? Are the necessary primitives implemented in NLW now?

https://github.com/NetLogo/Tortoise/wiki/Unimplemented-Primitives still lists max-n-of and min-n-of them as unimplemented, and trying them out in NetLogo Web's command center confirms this. Maybe @TheBizzle can confirm, but I don't expect them to be implemented before we release 5.2.1.

Depends. I haven't exhaustively tested them, but I have them seemingly working on a branch. When's this release going to be happening?

I have them seemingly working on a branch

That's great news!

When's this release going to be happening?

Soon. But I don't know the exact date.

The one thing I'd like to avoid is having to maintain two versions of the model. I am tempted to put max-n-of/min-n-of back in the model right away, but it would mean that you'd have to merge your feature branch before the next time you update the Models Library in NLW. Would that be OK for you?

Yeah, that's totally fine by me.