<p>Hi Ranjan,</p>

<p>Your data has 20 rows on disk, but Armadillo stores matrices in a column-major form, so these matrices are transposed at load time.  See <a href="http://mlpack.org/docs/mlpack-git/doxygen.php?doc=matrices.html">http://mlpack.org/docs/mlpack-git/doxygen.php?doc=matrices.html</a> for more information (a more detailed tutorial is coming too but I have not pushed it yet).</p>

<p>Try using <code>.col()</code> where you are using <code>.row()</code> and this will probably help fix the issue.</p>

<p>Thanks,</p>

<p>Ryan</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">&mdash;<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly or <a href="https://github.com/mlpack/mlpack/issues/607#issuecomment-207817871">view it on GitHub</a><img alt="" height="1" src="https://github.com/notifications/beacon/AJ4bFCsE5HGudl2B2Hi-MhmzVydBzPgmks5p19rCgaJpZM4IDj0M.gif" width="1" /></p>
<div itemscope itemtype="http://schema.org/EmailMessage">
<div itemprop="action" itemscope itemtype="http://schema.org/ViewAction">
  <link itemprop="url" href="https://github.com/mlpack/mlpack/issues/607#issuecomment-207817871"></link>
  <meta itemprop="name" content="View Issue"></meta>
</div>
<meta itemprop="description" content="View this Issue on GitHub"></meta>
</div>