Technically, There is no difference between those two lines. The error might be because of "=" in the command. "Set" command does not take '='. Please try the following codes which both are identical.
if variable < 0 [set variable 0] if (variable > 0) = false [set variable 0]
Regards, Bahman On Monday, September 11, 2017, 9:04:28 PM GMT+4:30, rosuna [hidden email] [netlogo-users] <[hidden email]> wrote:
This is my question. I am writing a model. Please, take a look at these two
If variable < 0 [set variable = 0]
If (variable > 0) = false [set variable = 0]
The first writing leads to an error message, and the second one doesn't.
Therefore I know they are not equivalent.
My question is why is it, and what is the difference.