<span class='kw'>byrow</span> <span class='kw'>=</span> <span class='fl'>TRUE</span>)
<span class='no'>ymat</span> <span class='kw'>&lt;-</span> (<span class='no'>ymat</span> <span class='kw'>==</span> <span class='fu'><a href='https://rdrr.io/r/base/numeric.html'>as.numeric</a></span>(<span class='no'>iris</span>$<span class='no'>Species</span>)) + <span class='fl'>0</span>
<span class='co'>#with gradient descent and 2 hidden layers</span>
<span class='no'>amlmodel</span> <span class='kw'>&lt;-</span> <spa