ERROR: TypeError: non-boolean (Array{Float64,2}) used in boolean context

I think you need the solution suggested by @GunnarFarneback.

Generally though, you seem to be having difficulties with understanding and debugging your code (eg this problem yesterday). It is perfectly fine to ask here, but perhaps investing some time in learning to use the new debugger, or just learning to debug by printing (eg @show) would also help.

1 Like