s://rdrr.io/r/base/cbind.html'>cbind</a></span>(<span class='no'>iris</span>[,<span class='fl'>2</span>:<span class='fl'>4</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='no'>ymat</span> <span class='kw'>&lt;-</span> <span class='no'>iris</span>[,<span class='fl'>1</span>]
<span class='co'>#with gradient descent</span>
<span class='no'>amlmodel</span> <span class='kw'>&lt;-</span> <span 