<div dir="ltr">ah, yes, here it is:<div><br></div><div><a href="https://docs.scipy.org/doc/scipy-0.18.1/reference/tutorial/io.html">https://docs.scipy.org/doc/scipy-0.18.1/reference/tutorial/io.html</a><br></div><div><br></div><div>----</div><div><br></div><div><p style="margin:0px 0px 9.5px;color:rgb(51,51,51);font-family:"open sans",sans-serif;font-size:13px">So, in MATLAB, the struct array must be at least 2D, and we replicate that when we read into Scipy. If you want all length 1 dimensions squeezed out, try this:</p><div class="gmail-highlight-python" style="color:rgb(51,51,51);font-family:"open sans",sans-serif;font-size:13px"><div class="gmail-highlight" style="background-image:initial;background-position:initial;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial;background-color:rgb(238,255,204)"><span class="gmail-copybutton" title="Hide the prompts and output" style="border-color:rgb(51,51,51);border-style:none;border-width:0px;font-family:monospace;padding-left:0.2em;padding-right:0.2em;border-radius:0px 3px 0px 0px">>>></span><pre style="padding:9px;font-size:12px;border-radius:0px;margin-top:0px;margin-bottom:9.5px;line-height:19px;word-break:break-all;word-wrap:break-word;white-space:pre-wrap;background-color:rgb(245,245,245);border:none;overflow-x:auto;overflow-y:hidden"><span class="gmail-gp" style="color:rgb(198,93,9);font-weight:bold">>>> </span><span class="gmail-n">mat_contents</span> <span class="gmail-o" style="color:rgb(102,102,102)">=</span> <span class="gmail-n">sio</span><span class="gmail-o" style="color:rgb(102,102,102)">.</span><span class="gmail-n">loadmat</span><span class="gmail-p">(</span><span class="gmail-s1" style="color:rgb(64,112,160)">'octave_struct.mat'</span><span class="gmail-p">,</span> <span class="gmail-n">squeeze_me</span><span class="gmail-o" style="color:rgb(102,102,102)">=</span><span class="gmail-bp" style="color:rgb(0,112,32)">True</span><span class="gmail-p">)</span>
<span class="gmail-gp" style="color:rgb(198,93,9);font-weight:bold">>>> </span><span class="gmail-n">oct_struct</span> <span class="gmail-o" style="color:rgb(102,102,102)">=</span> <span class="gmail-n">mat_contents</span><span class="gmail-p">[</span><span class="gmail-s1" style="color:rgb(64,112,160)">'my_struct'</span><span class="gmail-p">]</span>
<span class="gmail-gp" style="color:rgb(198,93,9);font-weight:bold">>>> </span><span class="gmail-n">oct_struct</span><span class="gmail-o" style="color:rgb(102,102,102)">.</span><span class="gmail-n">shape</span>
______________________________<wbr>_________________<br>SciPy-User mailing list<br><a href="mailto:SciPy-User@python.org" target="_blank">SciPy-User@python.org</a><br><a href="https://mail.python.org/mailman/listinfo/scipy-user" target="_blank">https://mail.python.org/mailma<wbr>n/listinfo/scipy-user</a><br></div></blockquote></div><br></div><br>______________________________<wbr>_________________<br>
SciPy-User mailing list<br>
<a href="mailto:SciPy-User@python.org" target="_blank">SciPy-User@python.org</a><br>
<a href="https://mail.python.org/mailman/listinfo/scipy-user" rel="noreferrer" target="_blank">https://mail.python.org/mailma<wbr>n/listinfo/scipy-user</a><br>
<br></blockquote></div><br></div>
</div></div></blockquote></div><br></div>