Skip to content

Commit

Permalink
built MSchatz patch 38
Browse files Browse the repository at this point in the history
  • Loading branch information
norlandrhagen committed May 4, 2020
1 parent 41a94c6 commit 9858239
Show file tree
Hide file tree
Showing 5 changed files with 33 additions and 64 deletions.
Binary file modified _build/doctrees/environment.pickle
Binary file not shown.
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ Depth Profile
:target: https://mybinder.org/v2/gh/simonscmap/pycmap/master?filepath=docs%2FViz_DepthProfile.ipynb


.. _API key: pycmap_api.html
.. _APIs parameters: pycmap_api.html
.. _APIs vizEngine: pycmap_api.html
.. _API key: https://cmap.readthedocs.io/en/latest/user_guide/API_ref/pycmap_api/pycmap_api_ref.html
.. _APIs parameters: https://cmap.readthedocs.io/en/latest/user_guide/API_ref/pycmap_api/pycmap_api_ref.html
.. _`APIs vizEngine`: https://cmap.readthedocs.io/en/latest/user_guide/API_ref/pycmap_api/pycmap_api_ref.html


.. method:: plot_depth_profile(tables, variables, dt1, dt2, lat1, lat2, lon1, lon2, depth1, depth2, exportDataFlag=False, show=True)
Expand All @@ -37,6 +37,7 @@ Depth Profile
python list. One may use the returned objects to modify the graph
properties.


.. note::
This method requires a valid `API key`_. It is not necessary to set the
API key every time because the API properties are stored locally after
Expand All @@ -53,23 +54,24 @@ Depth Profile
Variable short name which directly corresponds to a field name in the table. A full list of variable short names can be found in :ref:`Catalog`.
**dt1: string**
Start date or datetime. This parameter sets the lower bound of the temporal cut.
Example values: '2016-05-25' or '2017-12-10 17:25:00'
Example values: '2016-05-25' or '2017-12-10 17:25:00'.
**dt2: string**
End date or datetime. This parameter sets the upper bound of the temporal cut.
End date or datetime. This parameter sets the upper bound of the temporal cut. Example values: '2016-05-25' or '2017-12-10 17:25:00'.
**lat1: float**
Start latitude [degree N]. This parameter sets the lower bound of the meridional cut. Note latitude ranges from -90° to 90°.
**lat2: float**
End latitude [degree N]. This parameter sets the upper bound of the meridional cut. Note latitude ranges from -90° to 90°.
**lon1: float**
Start longitude [degree E]. This parameter sets the lower bound of the zonal cut. Note latitude ranges from -180° to 180°.
Start longitude [degree E]. This parameter sets the lower bound of the zonal cut. Note longitude ranges from -180° to 180°.
**lon2: float**
End longitude [degree E]. This parameter sets the upper bound of the zonal cut. Note latitude ranges from -180° to 180°.
End longitude [degree E]. This parameter sets the upper bound of the zonal cut. Note longitude ranges from -180° to 180°.
**depth1: float**
Start depth [m]. This parameter sets the lower bound of the vertical cut. Note depth is a positive number (it is 0 at surface and grows towards ocean floor).
Start depth [m]. This parameter sets the lower bound of the vertical cut. Note depth is a positive number (it is 0 at the surface and increases towards the ocean floor).
**depth2: float**
End depth [m]. This parameter sets the upper bound of the vertical cut. Note depth is a positive number (it is 0 at surface and grows towards ocean floor).
End depth [m]. This parameter sets the upper bound of the vertical cut. Note depth is a positive number (it is 0 at the surface and increases towards the ocean floor).
**exportDataFlag: boolean, default: False**
If True, the graph data points are stored on the local machine. The export path and file format are set by the `APIs parameters`_.

**show: boolean, default: True**
If True, the graph object is returned and is displayed. The graph file is saved on the local machine at the figureDir directory.
If False, the graph object is returned but not displayed.
Expand All @@ -78,6 +80,7 @@ Depth Profile


:returns\:: list of graph objects

A list of graph objects. Below are the graph's properties and methods.

:Properties:
Expand All @@ -92,11 +95,11 @@ Depth Profile
**width: int**
Graph's width in pixels.
**xlabel: str**
The graphs's x-axis label.
Graphs's x-axis label.
**ylabel: str**
The graphs's y-axis label.
Graphs's y-axis label.
**title: str**
The graphs's title.
Graphs's title.

:Methods:
**render()**
Expand Down Expand Up @@ -155,27 +158,6 @@ changed by: ``pycmap.API(vizEngine='bokeh')``



.. code-block:: python
# here is how to modify a graph:
go[1].cmap = 'PRGn'
go[1].vmin = 0
go[1].vmax = 5e-5
go[1].width = 900
go[1].height = 700
go[1].render()
|
.. raw:: html

<iframe src="../../../../_static/pycmap_tutorial_viz/html/depth_profile_modified_argo_merge_chl_adj.html" frameborder = 0 height="650px" width="100%">></iframe>






.. figure:: /_static/overview_icons/sql.png
:scale: 10 %
Expand Down
2 changes: 1 addition & 1 deletion _build/html/searchindex.js

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -243,53 +243,53 @@
by depth: at each depth level the mean and standard deviation of the
variable values within the space-time constraints are computed. The
sequence of these values construct the depth profile.</p>
<p>Change the <a class="reference external" href="pycmap_api.html">APIs vizEngine</a> parameter if you wish to use a different
<p>Change the <a class="reference external" href="https://cmap.readthedocs.io/en/latest/user_guide/API_ref/pycmap_api/pycmap_api_ref.html">APIs vizEngine</a> parameter if you wish to use a different
visualization library. Returns the generated graph objects in form of a
python list. One may use the returned objects to modify the graph
properties.</p>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>This method requires a valid <a class="reference external" href="pycmap_api.html">API key</a>. It is not necessary to set the
<p>This method requires a valid <a class="reference external" href="https://cmap.readthedocs.io/en/latest/user_guide/API_ref/pycmap_api/pycmap_api_ref.html">API key</a>. It is not necessary to set the
API key every time because the API properties are stored locally after
being called the first time.</p>
</div>
<div class="line-block">
<div class="line"><br /></div>
</div>
<dl class="field-list simple">
<dl class="field-list">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><dl class="simple">
<dt><strong>tables: list of string</strong></dt><dd><p>Table names (each dataset is stored in a table). A full list of table names can be found in <a class="reference internal" href="../../../../catalog/catalog.html#catalog"><span class="std std-ref">Data Catalog</span></a>.</p>
</dd>
<dt><strong>variable: list of string</strong></dt><dd><p>Variable short name which directly corresponds to a field name in the table. A full list of variable short names can be found in <a class="reference internal" href="../../../../catalog/catalog.html#catalog"><span class="std std-ref">Data Catalog</span></a>.</p>
</dd>
<dt><strong>dt1: string</strong></dt><dd><p>Start date or datetime. This parameter sets the lower bound of the temporal cut.
Example values: ‘2016-05-25’ or ‘2017-12-10 17:25:00’</p>
Example values: ‘2016-05-25’ or ‘2017-12-10 17:25:00’.</p>
</dd>
<dt><strong>dt2: string</strong></dt><dd><p>End date or datetime. This parameter sets the upper bound of the temporal cut.</p>
<dt><strong>dt2: string</strong></dt><dd><p>End date or datetime. This parameter sets the upper bound of the temporal cut. Example values: ‘2016-05-25’ or ‘2017-12-10 17:25:00’.</p>
</dd>
<dt><strong>lat1: float</strong></dt><dd><p>Start latitude [degree N]. This parameter sets the lower bound of the meridional cut. Note latitude ranges from -90° to 90°.</p>
</dd>
<dt><strong>lat2: float</strong></dt><dd><p>End latitude [degree N]. This parameter sets the upper bound of the meridional cut. Note latitude ranges from -90° to 90°.</p>
</dd>
<dt><strong>lon1: float</strong></dt><dd><p>Start longitude [degree E]. This parameter sets the lower bound of the zonal cut. Note latitude ranges from -180° to 180°.</p>
<dt><strong>lon1: float</strong></dt><dd><p>Start longitude [degree E]. This parameter sets the lower bound of the zonal cut. Note longitude ranges from -180° to 180°.</p>
</dd>
<dt><strong>lon2: float</strong></dt><dd><p>End longitude [degree E]. This parameter sets the upper bound of the zonal cut. Note latitude ranges from -180° to 180°.</p>
<dt><strong>lon2: float</strong></dt><dd><p>End longitude [degree E]. This parameter sets the upper bound of the zonal cut. Note longitude ranges from -180° to 180°.</p>
</dd>
<dt><strong>depth1: float</strong></dt><dd><p>Start depth [m]. This parameter sets the lower bound of the vertical cut. Note depth is a positive number (it is 0 at surface and grows towards ocean floor).</p>
<dt><strong>depth1: float</strong></dt><dd><p>Start depth [m]. This parameter sets the lower bound of the vertical cut. Note depth is a positive number (it is 0 at the surface and increases towards the ocean floor).</p>
</dd>
<dt><strong>depth2: float</strong></dt><dd><p>End depth [m]. This parameter sets the upper bound of the vertical cut. Note depth is a positive number (it is 0 at surface and grows towards ocean floor).</p>
<dt><strong>depth2: float</strong></dt><dd><p>End depth [m]. This parameter sets the upper bound of the vertical cut. Note depth is a positive number (it is 0 at the surface and increases towards the ocean floor).</p>
</dd>
<dt><strong>exportDataFlag: boolean, default: False</strong></dt><dd><p>If True, the graph data points are stored on the local machine. The export path and file format are set by the <a class="reference external" href="pycmap_api.html">APIs parameters</a>.</p>
<dt><strong>exportDataFlag: boolean, default: False</strong></dt><dd><p>If True, the graph data points are stored on the local machine. The export path and file format are set by the <a class="reference external" href="https://cmap.readthedocs.io/en/latest/user_guide/API_ref/pycmap_api/pycmap_api_ref.html">APIs parameters</a>.</p>
</dd>
<dt><strong>show: boolean, default: True</strong></dt><dd><p>If True, the graph object is returned and is displayed. The graph file is saved on the local machine at the figureDir directory.
If False, the graph object is returned but not displayed.</p>
</dd>
</dl>
</dd>
<dt class="field-even">Returns:</dt>
<dd class="field-even"><p>list of graph objects
A list of graph objects. Below are the graph’s properties and methods.</p>
<dd class="field-even"><p>list of graph objects</p>
<p>A list of graph objects. Below are the graph’s properties and methods.</p>
<dl class="field-list simple">
<dt class="field-odd">Properties</dt>
<dd class="field-odd"><dl class="simple">
Expand All @@ -303,11 +303,11 @@
</dd>
<dt><strong>width: int</strong></dt><dd><p>Graph’s width in pixels.</p>
</dd>
<dt><strong>xlabel: str</strong></dt><dd><p>The graphs’s x-axis label.</p>
<dt><strong>xlabel: str</strong></dt><dd><p>Graphs’s x-axis label.</p>
</dd>
<dt><strong>ylabel: str</strong></dt><dd><p>The graphs’s y-axis label.</p>
<dt><strong>ylabel: str</strong></dt><dd><p>Graphs’s y-axis label.</p>
</dd>
<dt><strong>title: str</strong></dt><dd><p>The graphs’s title.</p>
<dt><strong>title: str</strong></dt><dd><p>Graphs’s title.</p>
</dd>
</dl>
</dd>
Expand Down Expand Up @@ -360,20 +360,7 @@ <h2>Example:<a class="headerlink" href="#example" title="Permalink to this headl
<iframe src="../../../../_static/pycmap_tutorial_viz/html/depth_profile_argo_merge_chl_adj.html" frameborder = 0 height="450px" width="100%">></iframe><div class="line-block">
<div class="line"><br /></div>
</div>
<iframe src="../../../../_static/pycmap_tutorial_viz/html/depth_profile_CHL.html" frameborder = 0 height="450px" width="100%">></iframe><div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="c1"># here is how to modify a graph:</span>

<span class="n">go</span><span class="p">[</span><span class="mi">1</span><span class="p">]</span><span class="o">.</span><span class="n">cmap</span> <span class="o">=</span> <span class="s1">&#39;PRGn&#39;</span>
<span class="n">go</span><span class="p">[</span><span class="mi">1</span><span class="p">]</span><span class="o">.</span><span class="n">vmin</span> <span class="o">=</span> <span class="mi">0</span>
<span class="n">go</span><span class="p">[</span><span class="mi">1</span><span class="p">]</span><span class="o">.</span><span class="n">vmax</span> <span class="o">=</span> <span class="mf">5e-5</span>
<span class="n">go</span><span class="p">[</span><span class="mi">1</span><span class="p">]</span><span class="o">.</span><span class="n">width</span> <span class="o">=</span> <span class="mi">900</span>
<span class="n">go</span><span class="p">[</span><span class="mi">1</span><span class="p">]</span><span class="o">.</span><span class="n">height</span> <span class="o">=</span> <span class="mi">700</span>
<span class="n">go</span><span class="p">[</span><span class="mi">1</span><span class="p">]</span><span class="o">.</span><span class="n">render</span><span class="p">()</span>
</pre></div>
</div>
<div class="line-block">
<div class="line"><br /></div>
</div>
<iframe src="../../../../_static/pycmap_tutorial_viz/html/depth_profile_modified_argo_merge_chl_adj.html" frameborder = 0 height="650px" width="100%">></iframe><div class="figure align-default">
<iframe src="../../../../_static/pycmap_tutorial_viz/html/depth_profile_CHL.html" frameborder = 0 height="450px" width="100%">></iframe><div class="figure align-default">
<img alt="../../../../_images/sql.png" src="../../../../_images/sql.png" style="width: 51.2px; height: 51.2px;" />
</div>
<p><strong>SQL Statement</strong></p>
Expand Down Expand Up @@ -401,7 +388,7 @@ <h2>Example:<a class="headerlink" href="#example" title="Permalink to this headl
<p>
&copy; Copyright
<span class="lastupdated">
Last updated on Apr 01, 2020.
Last updated on May 04, 2020.
</span>

</p>
Expand Down

0 comments on commit 9858239

Please sign in to comment.