ncplot 0.4.1__tar.gz → 0.4.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (37) hide show
  1. {ncplot-0.4.1 → ncplot-0.4.2}/PKG-INFO +3 -3
  2. {ncplot-0.4.1 → ncplot-0.4.2}/README.md +2 -2
  3. ncplot-0.4.2/docs-site/archive/v0.4.1/api.html +172 -0
  4. ncplot-0.4.2/docs-site/archive/versions.json +3 -0
  5. ncplot-0.4.2/docs-site/assets/css/style.css +926 -0
  6. ncplot-0.4.2/docs-site/assets/img/favicon.svg +15 -0
  7. ncplot-0.4.2/docs-site/assets/img/ncplot_wordmark.svg +4 -0
  8. ncplot-0.4.2/docs-site/assets/img/pml_logo.jpg +0 -0
  9. ncplot-0.4.2/docs-site/assets/js/main.js +105 -0
  10. {ncplot-0.4.1 → ncplot-0.4.2}/docs-site/version-history.html +3 -1
  11. {ncplot-0.4.1 → ncplot-0.4.2}/ncplot/plot.py +5 -1
  12. {ncplot-0.4.1 → ncplot-0.4.2}/ncplot/utils.py +26 -0
  13. {ncplot-0.4.1 → ncplot-0.4.2}/ncplot.egg-info/SOURCES.txt +6 -0
  14. {ncplot-0.4.1 → ncplot-0.4.2}/setup.py +1 -1
  15. ncplot-0.4.1/docs-site/archive/versions.json +0 -1
  16. {ncplot-0.4.1 → ncplot-0.4.2}/LICENSE +0 -0
  17. {ncplot-0.4.1 → ncplot-0.4.2}/MANIFEST.in +0 -0
  18. {ncplot-0.4.1 → ncplot-0.4.2}/docs-site/.nojekyll +0 -0
  19. {ncplot-0.4.1 → ncplot-0.4.2}/docs-site/README.md +0 -0
  20. {ncplot-0.4.1 → ncplot-0.4.2}/docs-site/about.html +0 -0
  21. {ncplot-0.4.1 → ncplot-0.4.2}/docs-site/api.html +0 -0
  22. {ncplot-0.4.1/docs-site → ncplot-0.4.2/docs-site/archive/v0.4.1}/assets/css/style.css +0 -0
  23. {ncplot-0.4.1/docs-site → ncplot-0.4.2/docs-site/archive/v0.4.1}/assets/img/favicon.svg +0 -0
  24. {ncplot-0.4.1/docs-site → ncplot-0.4.2/docs-site/archive/v0.4.1}/assets/img/ncplot_wordmark.svg +0 -0
  25. {ncplot-0.4.1/docs-site → ncplot-0.4.2/docs-site/archive/v0.4.1}/assets/img/pml_logo.jpg +0 -0
  26. {ncplot-0.4.1/docs-site → ncplot-0.4.2/docs-site/archive/v0.4.1}/assets/js/main.js +0 -0
  27. {ncplot-0.4.1 → ncplot-0.4.2}/docs-site/example/plot.html +0 -0
  28. {ncplot-0.4.1 → ncplot-0.4.2}/docs-site/index.html +0 -0
  29. {ncplot-0.4.1 → ncplot-0.4.2}/docs-site/installing.html +0 -0
  30. {ncplot-0.4.1 → ncplot-0.4.2}/docs-site/quickstart.html +0 -0
  31. {ncplot-0.4.1 → ncplot-0.4.2}/ncplot/__init__.py +0 -0
  32. {ncplot-0.4.1 → ncplot-0.4.2}/ncplot/command_line.py +0 -0
  33. {ncplot-0.4.1 → ncplot-0.4.2}/ncplot/deprecated.py +0 -0
  34. {ncplot-0.4.1 → ncplot-0.4.2}/ncplot/xarray.py +0 -0
  35. {ncplot-0.4.1 → ncplot-0.4.2}/pyproject.toml +0 -0
  36. {ncplot-0.4.1 → ncplot-0.4.2}/requirements.txt +0 -0
  37. {ncplot-0.4.1 → ncplot-0.4.2}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: ncplot
3
- Version: 0.4.1
3
+ Version: 0.4.2
4
4
  Summary: Interactive viewing of NetCDF data
5
5
  Home-page: https://github.com/pmlmodelling/ncplot
6
6
  Author: Robert Wilson
@@ -51,7 +51,7 @@ Dynamic: summary
51
51
  </p>
52
52
 
53
53
  > [!TIP]
54
- > 📖 **New here?** The NCPlot website — installing, a quickstart, the API reference, and more — lives at **[pmlmodelling.github.io/ncplot](https://pmlmodelling.github.io/ncplot/)**.
54
+ > 📖 **New here?** The NCPlot website — installing, a quickstart, the API reference, and more — lives at **[plymouthmarinelaboratory.github.io/ncplot](https://plymouthmarinelaboratory.github.io/ncplot/)**.
55
55
 
56
56
  [![pypi](https://img.shields.io/pypi/v/ncplot.svg)](https://pypi.python.org/pypi/ncplot/)
57
57
  [![Documentation Status](https://readthedocs.org/projects/ncplot/badge/?version=latest)](https://ncplot.readthedocs.io/en/latest/?badge=latest)
@@ -150,7 +150,7 @@ ncplot example.nc
150
150
 
151
151
  # Reference and tutorials
152
152
 
153
- A full API reference, and a how-to guide are available at the [NCPlot website](https://pmlmodelling.github.io/ncplot/) and on [readthedocs](https://ncplot.readthedocs.io/en/latest/).
153
+ A full API reference, and a how-to guide are available at the [NCPlot website](https://plymouthmarinelaboratory.github.io/ncplot/) and on [readthedocs](https://ncplot.readthedocs.io/en/latest/).
154
154
 
155
155
 
156
156
 
@@ -3,7 +3,7 @@
3
3
  </p>
4
4
 
5
5
  > [!TIP]
6
- > 📖 **New here?** The NCPlot website — installing, a quickstart, the API reference, and more — lives at **[pmlmodelling.github.io/ncplot](https://pmlmodelling.github.io/ncplot/)**.
6
+ > 📖 **New here?** The NCPlot website — installing, a quickstart, the API reference, and more — lives at **[plymouthmarinelaboratory.github.io/ncplot](https://plymouthmarinelaboratory.github.io/ncplot/)**.
7
7
 
8
8
  [![pypi](https://img.shields.io/pypi/v/ncplot.svg)](https://pypi.python.org/pypi/ncplot/)
9
9
  [![Documentation Status](https://readthedocs.org/projects/ncplot/badge/?version=latest)](https://ncplot.readthedocs.io/en/latest/?badge=latest)
@@ -102,7 +102,7 @@ ncplot example.nc
102
102
 
103
103
  # Reference and tutorials
104
104
 
105
- A full API reference, and a how-to guide are available at the [NCPlot website](https://pmlmodelling.github.io/ncplot/) and on [readthedocs](https://ncplot.readthedocs.io/en/latest/).
105
+ A full API reference, and a how-to guide are available at the [NCPlot website](https://plymouthmarinelaboratory.github.io/ncplot/) and on [readthedocs](https://ncplot.readthedocs.io/en/latest/).
106
106
 
107
107
 
108
108
 
@@ -0,0 +1,172 @@
1
+ <!doctype html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <meta name="robots" content="noindex, follow">
6
+ <meta name="viewport" content="width=device-width, initial-scale=1">
7
+ <title>API Reference — NCPlot</title>
8
+ <meta name="description" content="Function reference for ncplot: view(), the ncplot.xarray accessor, and the ncplot command line tool.">
9
+ <link rel="icon" type="image/svg+xml" href="assets/img/favicon.svg">
10
+ <link rel="preconnect" href="https://fonts.googleapis.com">
11
+ <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
12
+ <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Poppins:wght@600;700&family=JetBrains+Mono:wght@400;500&display=swap" rel="stylesheet">
13
+ <link rel="stylesheet" href="assets/css/style.css">
14
+ </head>
15
+ <body>
16
+
17
+ <header class="site-header">
18
+ <div class="container nav">
19
+ <a class="brand" href="../../index.html">
20
+ <img src="assets/img/ncplot_wordmark.svg" alt="NCPlot">
21
+ <span class="brand-version">v0.4.1 (archived)</span>
22
+ </a>
23
+ <nav class="nav-links" id="nav-links">
24
+ <a href="../../version-history.html" data-page="version-history.html">Version history</a>
25
+ </nav>
26
+ <div class="nav-actions">
27
+ <a class="icon-btn" href="https://github.com/pmlmodelling/ncplot" target="_blank" rel="noopener" aria-label="NCPlot on GitHub">
28
+ <svg viewBox="0 0 24 24" fill="currentColor"><path fill-rule="evenodd" d="M12 .5C5.73.5.5 5.74.5 12.09c0 5.08 3.29 9.38 7.86 10.9.57.1.79-.25.79-.55 0-.27-.01-1.17-.02-2.12-3.2.7-3.88-1.36-3.88-1.36-.53-1.34-1.29-1.7-1.29-1.7-1.05-.72.08-.71.08-.71 1.17.08 1.78 1.2 1.78 1.2 1.03 1.77 2.71 1.26 3.37.96.1-.75.4-1.26.73-1.55-2.56-.29-5.26-1.28-5.26-5.71 0-1.26.45-2.29 1.19-3.09-.12-.29-.52-1.46.11-3.05 0 0 .97-.31 3.18 1.18a11.1 11.1 0 0 1 5.79 0c2.2-1.49 3.17-1.18 3.17-1.18.64 1.59.24 2.76.12 3.05.74.8 1.18 1.83 1.18 3.09 0 4.44-2.7 5.42-5.28 5.7.42.36.78 1.08.78 2.17 0 1.57-.01 2.83-.01 3.22 0 .3.21.66.8.55A10.6 10.6 0 0 0 23.5 12.1C23.5 5.74 18.27.5 12 .5Z"/></svg>
29
+ </a>
30
+ <button class="nav-toggle" id="nav-toggle" aria-label="Toggle menu" aria-expanded="false">
31
+ <svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round"><line x1="3" y1="12" x2="21" y2="12"/><line x1="3" y1="6" x2="21" y2="6"/><line x1="3" y1="18" x2="21" y2="18"/></svg>
32
+ </button>
33
+ </div>
34
+ </div>
35
+ </header>
36
+
37
+ <div class="page-hero">
38
+ <div class="container">
39
+ <div class="breadcrumb"><a href="../../index.html">Home</a> / API</div>
40
+ <h1>API reference</h1>
41
+ <p class="lead">NCPlot has one core function — <code>view()</code> — reachable three ways: directly from the top-level <code>ncplot</code> namespace, via the <code>ncplot.xarray</code> accessor, or from the <code>ncplot</code> command line tool.</p>
42
+ </div>
43
+ </div>
44
+
45
+ <div class="container docs-layout">
46
+ <aside class="docs-toc">
47
+ <div class="docs-toc-title">Reference</div>
48
+ <ul>
49
+ <li><a href="#view">view</a></li>
50
+ <li><a href="#xarray-accessor">ncplot.xarray accessor</a></li>
51
+ <li><a href="#cli">Command line</a></li>
52
+ </ul>
53
+ </aside>
54
+
55
+ <div class="docs-content">
56
+
57
+ <span class="kicker">Plotting</span>
58
+
59
+ <div class="api-card" id="view">
60
+ <div class="api-card__head"><div class="sig">ncplot.view(x, vars=None, autoscale=True, out=None, **kwargs)</div></div>
61
+ <div class="api-card__body">
62
+ <p>Plot the contents of a netCDF file, directory, remote URL, or xarray object.</p>
63
+ <details class="param-details" open>
64
+ <summary>Parameters</summary>
65
+ <p>Required:</p>
66
+ <ul class="param-list">
67
+ <li><code class="param-name">x</code><span class="param-tag">required</span><p>An xarray <code>Dataset</code>/<code>DataArray</code>, or a file path, directory, or remote (OPeNDAP/THREDDS) URL pointing to netCDF data.</p></li>
68
+ </ul>
69
+ <p>Optional:</p>
70
+ <ul class="param-list">
71
+ <li><code class="param-name">vars</code><p>A variable name, or list of variable names, to plot. If omitted, every variable in <code>x</code> is plotted.</p></li>
72
+ <li><code class="param-name">autoscale</code><p>Whether colour scales are set automatically from each variable's minimum and maximum values. Default <code>True</code>. Set to <code>False</code> to keep scales fixed, e.g. when comparing several plots.</p></li>
73
+ <li><code class="param-name">out</code><p>Path to save the plot to, instead of displaying it inline. Must end in <code>.html</code>.</p></li>
74
+ <li><code class="param-name">coast</code><p>Draw coastlines on map plots. Default <code>False</code>. Looks best with the optional <code>cartopy</code> dependency installed (see <a href="../../installing.html">Installing</a>).</p></li>
75
+ <li><code class="param-name">clim</code><p>A <code>(min, max)</code> tuple fixing the colour scale range, overriding <code>autoscale</code> for that call.</p></li>
76
+ </ul>
77
+ </details>
78
+ </div>
79
+ </div>
80
+
81
+ <span class="kicker">Accessors</span>
82
+
83
+ <div class="api-card" id="xarray-accessor">
84
+ <div class="api-card__head"><div class="sig">ncplot.xarray — Dataset.ncplot.view() / DataArray.ncplot.view()</div></div>
85
+ <div class="api-card__body">
86
+ <p>Importing <code>ncplot.xarray</code> registers a <code>.ncplot</code> accessor on every xarray <code>Dataset</code> and <code>DataArray</code>, mirroring xarray's own <code>.plot</code> accessor:</p>
87
+ <div class="code-block">
88
+ <div class="code-card__bar">
89
+ <div class="code-card__dots"><span></span><span></span><span></span></div>
90
+ <span class="code-card__label">python</span>
91
+ </div>
92
+ <pre><span class="tok-kw">import</span> ncplot.xarray
93
+ <span class="tok-kw">import</span> xarray <span class="tok-kw">as</span> xr
94
+
95
+ ds = xr.<span class="tok-fn">open_dataset</span>(<span class="tok-str">"example.nc"</span>)
96
+ ds.ncplot.<span class="tok-fn">view</span>(vars=<span class="tok-str">"sst"</span>, coast=<span class="tok-kw">True</span>)</pre>
97
+ </div>
98
+ <p><code>Dataset.ncplot.view(vars=None, **kwargs)</code> and <code>DataArray.ncplot.view(vars=None, **kwargs)</code> both call <a href="#view"><code>view()</code></a> underneath with <code>self</code> as <code>x</code> — every keyword argument documented above works here too.</p>
99
+ </div>
100
+ </div>
101
+
102
+ <span class="kicker">Command line</span>
103
+
104
+ <div class="api-card" id="cli">
105
+ <div class="api-card__head"><div class="sig">ncplot &lt;file [file ...]&gt;</div></div>
106
+ <div class="api-card__body">
107
+ <p>Installing NCPlot adds an <code>ncplot</code> console command. Give it one or more existing file paths or URLs and it opens an interactive view — a single argument is passed straight to <a href="#view"><code>view()</code></a>, multiple arguments are passed as a list:</p>
108
+ <div class="code-block">
109
+ <div class="code-card__bar">
110
+ <div class="code-card__dots"><span></span><span></span><span></span></div>
111
+ <span class="code-card__label">console</span>
112
+ </div>
113
+ <pre>$ ncplot example.nc
114
+ $ ncplot one.nc two.nc</pre>
115
+ </div>
116
+ </div>
117
+ </div>
118
+
119
+ </div>
120
+ </div>
121
+
122
+ <footer class="site-footer">
123
+ <div class="container footer-pml">
124
+ <a href="https://pml.ac.uk/" target="_blank" rel="noopener"><img src="assets/img/pml_logo.jpg" alt="Plymouth Marine Laboratory"></a>
125
+ <span>Developed by the Environmental Intelligence group at Plymouth Marine Laboratory</span>
126
+ </div>
127
+ <div class="container footer-top">
128
+ <div class="footer-brand">
129
+ <img src="assets/img/ncplot_wordmark.svg" alt="NCPlot">
130
+ <p>Instant, interactive viewing of netCDF files in Python or on the command line.</p>
131
+ <div class="footer-social">
132
+ <a href="https://github.com/pmlmodelling/ncplot" target="_blank" rel="noopener" aria-label="GitHub">
133
+ <svg viewBox="0 0 24 24" fill="currentColor"><path fill-rule="evenodd" d="M12 .5C5.73.5.5 5.74.5 12.09c0 5.08 3.29 9.38 7.86 10.9.57.1.79-.25.79-.55 0-.27-.01-1.17-.02-2.12-3.2.7-3.88-1.36-3.88-1.36-.53-1.34-1.29-1.7-1.29-1.7-1.05-.72.08-.71.08-.71 1.17.08 1.78 1.2 1.78 1.2 1.03 1.77 2.71 1.26 3.37.96.1-.75.4-1.26.73-1.55-2.56-.29-5.26-1.28-5.26-5.71 0-1.26.45-2.29 1.19-3.09-.12-.29-.52-1.46.11-3.05 0 0 .97-.31 3.18 1.18a11.1 11.1 0 0 1 5.79 0c2.2-1.49 3.17-1.18 3.17-1.18.64 1.59.24 2.76.12 3.05.74.8 1.18 1.83 1.18 3.09 0 4.44-2.7 5.42-5.28 5.7.42.36.78 1.08.78 2.17 0 1.57-.01 2.83-.01 3.22 0 .3.21.66.8.55A10.6 10.6 0 0 0 23.5 12.1C23.5 5.74 18.27.5 12 .5Z"/></svg>
134
+ </a>
135
+ <a href="mailto:rwi@pml.ac.uk" aria-label="Email">
136
+ <svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M4 4h16c1.1 0 2 .9 2 2v12c0 1.1-.9 2-2 2H4c-1.1 0-2-.9-2-2V6c0-1.1.9-2 2-2z"/><polyline points="22,6 12,13 2,6"/></svg>
137
+ </a>
138
+ </div>
139
+ </div>
140
+ <div class="footer-col">
141
+ <h4>Documentation</h4>
142
+ <ul>
143
+ <li><a href="../../installing.html">Installing</a></li>
144
+ <li><a href="../../quickstart.html">Quickstart</a></li>
145
+ <li><a href="api.html">API reference</a></li>
146
+ </ul>
147
+ </div>
148
+ <div class="footer-col">
149
+ <h4>Project</h4>
150
+ <ul>
151
+ <li><a href="../../about.html">About &amp; contact</a></li>
152
+ <li><a href="../../version-history.html">Version history</a></li>
153
+ <li><a href="https://github.com/pmlmodelling/ncplot" target="_blank" rel="noopener">GitHub repository</a></li>
154
+ <li><a href="https://github.com/pmlmodelling/ncplot/issues" target="_blank" rel="noopener">Report an issue</a></li>
155
+ <li><a href="https://pypi.org/project/ncplot/" target="_blank" rel="noopener">PyPI package</a></li>
156
+ <li><a href="https://anaconda.org/conda-forge/ncplot" target="_blank" rel="noopener">conda-forge package</a></li>
157
+ </ul>
158
+ </div>
159
+ </div>
160
+ <div class="container footer-bottom">
161
+ <span>© 2026 Plymouth Marine Laboratory. Released under the GNU GPLv3 license.</span>
162
+ <span>Built for quick, no-fuss netCDF viewing.</span>
163
+ </div>
164
+ </footer>
165
+
166
+ <button class="back-to-top" aria-label="Back to top">
167
+ <svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><line x1="12" y1="19" x2="12" y2="5"/><polyline points="5 12 12 5 19 12"/></svg>
168
+ </button>
169
+
170
+ <script src="assets/js/main.js"></script>
171
+ </body>
172
+ </html>
@@ -0,0 +1,3 @@
1
+ [
2
+ "0.4.1"
3
+ ]