Browse Source

NumPy

pull/140/head
Jure Šorn 1 year ago
parent
commit
1f057ed1fe
2 changed files with 4 additions and 4 deletions
  1. 4
      README.md
  2. 4
      index.html

4
README.md

@ -2650,8 +2650,8 @@ import numpy as np
```
```python
<array> = <array>.sum/min/mean/var/std(axis) # Passed dimension gets aggregated.
<array> = <array>.argmin(axis) # Returns indexes of smallest elements.
<array> = <array>.sum/min/mean/var/std([axis]) # Passed dimension gets aggregated.
<array> = <array>.argmin([axis]) # Returns indexes of smallest elements.
<array> = np.apply_along_axis(<func>, axis, <array>) # Func can return a scalar or array.
```

4
index.html

@ -2164,8 +2164,8 @@ drawer = cg.output.GraphvizOutput(output_file=filename)
&lt;array&gt; = &lt;array&gt;.flatten() <span class="hljs-comment"># Collapses array into one dimension.</span>
&lt;view&gt; = &lt;array&gt;.squeeze() <span class="hljs-comment"># Removes dimensions of length one.</span>
</code></pre>
<pre><code class="python language-python hljs">&lt;array&gt; = &lt;array&gt;.sum/min/mean/var/std(axis) <span class="hljs-comment"># Passed dimension gets aggregated.</span>
&lt;array&gt; = &lt;array&gt;.argmin(axis) <span class="hljs-comment"># Returns indexes of smallest elements.</span>
<pre><code class="python language-python hljs">&lt;array&gt; = &lt;array&gt;.sum/min/mean/var/std([axis]) <span class="hljs-comment"># Passed dimension gets aggregated.</span>
&lt;array&gt; = &lt;array&gt;.argmin([axis]) <span class="hljs-comment"># Returns indexes of smallest elements.</span>
&lt;array&gt; = np.apply_along_axis(&lt;func&gt;, axis, &lt;array&gt;) <span class="hljs-comment"># Func can return a scalar or array.</span>
</code></pre>
<ul>

Loading…
Cancel
Save