<div dir="ltr"><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, Feb 10, 2014 at 2:12 PM, eat <span dir="ltr"><<a href="mailto:e.antero.tammi@gmail.com" target="_blank">e.antero.tammi@gmail.com</a>></span> wrote:<br>
<blockquote style="margin:0px 0px 0px 0.8ex;padding-left:1ex;border-left-color:rgb(204,204,204);border-left-width:1px;border-left-style:solid" class="gmail_quote"><div dir="ltr"><br><div class="gmail_extra"><br><br><div class="gmail_quote">
<div>On Mon, Feb 10, 2014 at 9:08 PM, alex <span dir="ltr"><<a href="mailto:argriffi@ncsu.edu" target="_blank">argriffi@ncsu.edu</a>></span> wrote:<br>
<blockquote style="margin:0px 0px 0px 0.8ex;padding-left:1ex;border-left-color:rgb(204,204,204);border-left-width:1px;border-left-style:solid" class="gmail_quote"><div>On Mon, Feb 10, 2014 at 2:03 PM, eat <<a href="mailto:e.antero.tammi@gmail.com" target="_blank">e.antero.tammi@gmail.com</a>> wrote:<br>


> Rhetorical or not, but FWIW I'll prefer to take singular value decomposition<br>
> (u, s, vt= svd(x)) and then based on the singular values s I'll estimate a<br>
> "numerically feasible rank" r. Thus the diagonal of such hat matrix would be<br>
> (u[:, :r]** 2).sum(1).<br>
<br>
</div>It's a small detail but you probably want svd(x, full_matrices=False)<br>
to avoid anything NxN.<br></blockquote></div><div>Indeed.</div></div></div></div></blockquote><div> </div><div>I meant the entire diagonal not the trace of the projection matrix.</div><div> </div><div>My (not articulated) thought was that I use element wise multiplication together with dot products instead of the three dot products, however elementwise algebra is not very common in linear algebra based textbooks. </div>
<div> </div><div>The question is whether students and new user coming from `matrix` languages can translate formulas into code, or just copy formulas to code.</div><div>(It took me a while to get used to numpy and take advantage of it's features coming from GAUSS and Matlab.)</div>
<div> </div><div>OT since the precense or absence of matrix in numpy doesn't affect me.</div><div> </div><div>Josef</div><div> </div><blockquote style="margin:0px 0px 0px 0.8ex;padding-left:1ex;border-left-color:rgb(204,204,204);border-left-width:1px;border-left-style:solid" class="gmail_quote">
<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><div><br></div><div>Thanks,</div><div>-eat </div><div><blockquote style="margin:0px 0px 0px 0.8ex;padding-left:1ex;border-left-color:rgb(204,204,204);border-left-width:1px;border-left-style:solid" class="gmail_quote">

<div><div>_______________________________________________<br>
NumPy-Discussion mailing list<br>
<a href="mailto:NumPy-Discussion@scipy.org" target="_blank">NumPy-Discussion@scipy.org</a><br>
<a href="http://mail.scipy.org/mailman/listinfo/numpy-discussion" target="_blank">http://mail.scipy.org/mailman/listinfo/numpy-discussion</a><br>
</div></div></blockquote></div></div><br></div></div>
<br>_______________________________________________<br>
NumPy-Discussion mailing list<br>
<a href="mailto:NumPy-Discussion@scipy.org">NumPy-Discussion@scipy.org</a><br>
<a href="http://mail.scipy.org/mailman/listinfo/numpy-discussion" target="_blank">http://mail.scipy.org/mailman/listinfo/numpy-discussion</a><br>
<br></blockquote></div><br></div></div>