|
@@ -8,7 +8,7 @@
|
|
|
|
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
|
|
|
|
- <title>ipfml.utils — IPFML v0.3.3 documentation</title>
|
|
|
|
|
|
+ <title>ipfml.utils — IPFML v0.3.4 documentation</title>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@@ -58,7 +58,7 @@
|
|
|
|
|
|
|
|
|
|
<div class="version">
|
|
<div class="version">
|
|
- 0.3.3
|
|
|
|
|
|
+ 0.3.4
|
|
</div>
|
|
</div>
|
|
|
|
|
|
|
|
|
|
@@ -174,6 +174,12 @@
|
|
<col width="90%" />
|
|
<col width="90%" />
|
|
</colgroup>
|
|
</colgroup>
|
|
<tbody valign="top">
|
|
<tbody valign="top">
|
|
|
|
+<tr class="row-odd"><td><a class="reference internal" href="#ipfml.utils.get_indices_of_highest_values" title="ipfml.utils.get_indices_of_highest_values"><code class="xref py py-obj docutils literal notranslate"><span class="pre">get_indices_of_highest_values</span></code></a>(arr, n)</td>
|
|
|
|
+<td>Returns indices of n highest values from list or 1D numpy array</td>
|
|
|
|
+</tr>
|
|
|
|
+<tr class="row-even"><td><a class="reference internal" href="#ipfml.utils.get_indices_of_lowest_values" title="ipfml.utils.get_indices_of_lowest_values"><code class="xref py py-obj docutils literal notranslate"><span class="pre">get_indices_of_lowest_values</span></code></a>(arr, n)</td>
|
|
|
|
+<td>Returns indices of n highest values from list or 1D numpy array</td>
|
|
|
|
+</tr>
|
|
<tr class="row-odd"><td><a class="reference internal" href="#ipfml.utils.integral_area_simps" title="ipfml.utils.integral_area_simps"><code class="xref py py-obj docutils literal notranslate"><span class="pre">integral_area_simps</span></code></a>(y_values, dx)</td>
|
|
<tr class="row-odd"><td><a class="reference internal" href="#ipfml.utils.integral_area_simps" title="ipfml.utils.integral_area_simps"><code class="xref py py-obj docutils literal notranslate"><span class="pre">integral_area_simps</span></code></a>(y_values, dx)</td>
|
|
<td>Returns area under curves from provided data points using Simpsons rule</td>
|
|
<td>Returns area under curves from provided data points using Simpsons rule</td>
|
|
</tr>
|
|
</tr>
|
|
@@ -191,6 +197,66 @@
|
|
</tr>
|
|
</tr>
|
|
</tbody>
|
|
</tbody>
|
|
</table>
|
|
</table>
|
|
|
|
+<dl class="function">
|
|
|
|
+<dt id="ipfml.utils.get_indices_of_highest_values">
|
|
|
|
+<code class="descclassname">ipfml.utils.</code><code class="descname">get_indices_of_highest_values</code><span class="sig-paren">(</span><em>arr</em>, <em>n</em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/ipfml/utils.html#get_indices_of_highest_values"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#ipfml.utils.get_indices_of_highest_values" title="Permalink to this definition">¶</a></dt>
|
|
|
|
+<dd><p>Returns indices of n highest values from list or 1D numpy array</p>
|
|
|
|
+<table class="docutils field-list" frame="void" rules="none">
|
|
|
|
+<col class="field-name" />
|
|
|
|
+<col class="field-body" />
|
|
|
|
+<tbody valign="top">
|
|
|
|
+<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
|
|
|
|
+<li><strong>arr</strong> – List of numpy array</li>
|
|
|
|
+<li><strong>n</strong> – number of highest elements wanted</li>
|
|
|
|
+</ul>
|
|
|
|
+</td>
|
|
|
|
+</tr>
|
|
|
|
+<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last"><cite>n</cite> indices of highest values</p>
|
|
|
|
+</td>
|
|
|
|
+</tr>
|
|
|
|
+</tbody>
|
|
|
|
+</table>
|
|
|
|
+<p>Example:</p>
|
|
|
|
+<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="gp">>>> </span><span class="kn">from</span> <span class="nn">ipfml</span> <span class="k">import</span> <span class="n">utils</span>
|
|
|
|
+<span class="gp">>>> </span><span class="kn">import</span> <span class="nn">numpy</span> <span class="k">as</span> <span class="nn">np</span>
|
|
|
|
+<span class="gp">>>> </span><span class="n">arr</span> <span class="o">=</span> <span class="n">np</span><span class="o">.</span><span class="n">arange</span><span class="p">(</span><span class="mi">10</span><span class="p">)</span>
|
|
|
|
+<span class="gp">>>> </span><span class="n">indices</span> <span class="o">=</span> <span class="n">utils</span><span class="o">.</span><span class="n">get_indices_of_highest_values</span><span class="p">(</span><span class="n">arr</span><span class="p">,</span> <span class="mi">2</span><span class="p">)</span>
|
|
|
|
+<span class="gp">>>> </span><span class="n">indices</span>
|
|
|
|
+<span class="go">array([9, 8])</span>
|
|
|
|
+</pre></div>
|
|
|
|
+</div>
|
|
|
|
+</dd></dl>
|
|
|
|
+
|
|
|
|
+<dl class="function">
|
|
|
|
+<dt id="ipfml.utils.get_indices_of_lowest_values">
|
|
|
|
+<code class="descclassname">ipfml.utils.</code><code class="descname">get_indices_of_lowest_values</code><span class="sig-paren">(</span><em>arr</em>, <em>n</em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/ipfml/utils.html#get_indices_of_lowest_values"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#ipfml.utils.get_indices_of_lowest_values" title="Permalink to this definition">¶</a></dt>
|
|
|
|
+<dd><p>Returns indices of n highest values from list or 1D numpy array</p>
|
|
|
|
+<table class="docutils field-list" frame="void" rules="none">
|
|
|
|
+<col class="field-name" />
|
|
|
|
+<col class="field-body" />
|
|
|
|
+<tbody valign="top">
|
|
|
|
+<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
|
|
|
|
+<li><strong>arr</strong> – List of numpy array</li>
|
|
|
|
+<li><strong>n</strong> – number of highest elements wanted</li>
|
|
|
|
+</ul>
|
|
|
|
+</td>
|
|
|
|
+</tr>
|
|
|
|
+<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last"><cite>n</cite> indices of highest values</p>
|
|
|
|
+</td>
|
|
|
|
+</tr>
|
|
|
|
+</tbody>
|
|
|
|
+</table>
|
|
|
|
+<p>Example:</p>
|
|
|
|
+<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="gp">>>> </span><span class="kn">from</span> <span class="nn">ipfml</span> <span class="k">import</span> <span class="n">utils</span>
|
|
|
|
+<span class="gp">>>> </span><span class="kn">import</span> <span class="nn">numpy</span> <span class="k">as</span> <span class="nn">np</span>
|
|
|
|
+<span class="gp">>>> </span><span class="n">arr</span> <span class="o">=</span> <span class="n">np</span><span class="o">.</span><span class="n">arange</span><span class="p">(</span><span class="mi">10</span><span class="p">)</span>
|
|
|
|
+<span class="gp">>>> </span><span class="n">indices</span> <span class="o">=</span> <span class="n">utils</span><span class="o">.</span><span class="n">get_indices_of_lowest_values</span><span class="p">(</span><span class="n">arr</span><span class="p">,</span> <span class="mi">2</span><span class="p">)</span>
|
|
|
|
+<span class="gp">>>> </span><span class="n">indices</span>
|
|
|
|
+<span class="go">array([0, 1])</span>
|
|
|
|
+</pre></div>
|
|
|
|
+</div>
|
|
|
|
+</dd></dl>
|
|
|
|
+
|
|
<dl class="function">
|
|
<dl class="function">
|
|
<dt id="ipfml.utils.integral_area_simps">
|
|
<dt id="ipfml.utils.integral_area_simps">
|
|
<code class="descclassname">ipfml.utils.</code><code class="descname">integral_area_simps</code><span class="sig-paren">(</span><em>y_values</em>, <em>dx</em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/ipfml/utils.html#integral_area_simps"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#ipfml.utils.integral_area_simps" title="Permalink to this definition">¶</a></dt>
|
|
<code class="descclassname">ipfml.utils.</code><code class="descname">integral_area_simps</code><span class="sig-paren">(</span><em>y_values</em>, <em>dx</em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/ipfml/utils.html#integral_area_simps"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#ipfml.utils.integral_area_simps" title="Permalink to this definition">¶</a></dt>
|
|
@@ -200,7 +266,7 @@
|
|
<col class="field-body" />
|
|
<col class="field-body" />
|
|
<tbody valign="top">
|
|
<tbody valign="top">
|
|
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
|
|
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
|
|
-<li><strong>points</strong> – array of point coordinates</li>
|
|
|
|
|
|
+<li><strong>y_values</strong> – y values of curve</li>
|
|
<li><strong>dx</strong> – number of unit for x axis</li>
|
|
<li><strong>dx</strong> – number of unit for x axis</li>
|
|
</ul>
|
|
</ul>
|
|
</td>
|
|
</td>
|
|
@@ -230,7 +296,7 @@
|
|
<col class="field-body" />
|
|
<col class="field-body" />
|
|
<tbody valign="top">
|
|
<tbody valign="top">
|
|
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
|
|
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
|
|
-<li><strong>points</strong> – array of point coordinates</li>
|
|
|
|
|
|
+<li><strong>y_values</strong> – y values of curve</li>
|
|
<li><strong>dx</strong> – number of unit for x axis</li>
|
|
<li><strong>dx</strong> – number of unit for x axis</li>
|
|
</ul>
|
|
</ul>
|
|
</td>
|
|
</td>
|