Skip to content

Commit b491d95

Browse files
committed
Improvements in documentation
1 parent 748078d commit b491d95

9 files changed

+81
-52
lines changed

docs/authors.md

+2-1
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,5 @@ None yet. Why not be the first?
66

77
### Other contributors
88

9-
Those who have given their feedback and reported bugs can be found in [https://github.com/wxguy/wrfplot/issues](https://github.com/wxguy/wrfplot/issues).
9+
Those who have given their feedback and reported bugs can be found in
10+
[https://github.com/wxguy/wrfplot/issues](https://github.com/wxguy/wrfplot/issues).

docs/colormaps.md

+8-4
Large diffs are not rendered by default.

docs/index.md

+23-8
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,42 @@
11
## About wrfplot
22

3-
`wrfplot` is a Command Line application written in Python Programming Language to plot set of diagnostic forecast variables from Weather Research and Forecasting (WRF) atmospheric model output file. Though, WRF model output files are simple NetCDF, it requires one to install various software and libraries to plot even a single variable. Python has many modules that can deal with WRF model output data set. However, setting up these libraries, plotting variables through reading a lot of documentation is a tedious process. wrfplot aims to fill this gap by proving an application that is easy to install and use.
4-
5-
The idea of developing `wrfplot` came to my mind as I frequently revisit the same code base again and again to tweak a few lines of code to get changes in final plots. Therefore, I was looking for a command line application that would help me to generate a common WRF model forecast images by providing appropriate command line options. I could not find any and hence created one.
3+
`wrfplot` is a Command Line application, written in Python programming language,
4+
to plot a set of diagnostic forecast variables from the Weather Research and
5+
Forecasting (WRF) atmospheric model output file.
6+
Though, WRF model output files are ust a NetCDF file,
7+
it requires one to install various software and libraries to plot a single variable.
8+
Python has many modules that can deal with WRF model output data set.
9+
However, setting up these libraries, plotting variables through reading a lot of documentation is a tedious process.
10+
`wrfplot` aims to fill this gap by proving an application that is straightforward to install and use.
11+
12+
The idea of developing `wrfplot` came to my mind as I frequently revisit the same code base again and again to tweak a
13+
few lines of code to get changes in final plots.
14+
Therefore, I was looking for a command line application
15+
that would help me to generate a common WRF model forecast images by providing appropriate command line options.
16+
I could not find any and hence created one.
617

718
## Use Cases
819

9-
A typical use case of `wrfplot` would be to include as part of your WRF model run framework to plotting of variables immediately after the model run is completed. The other use case would be to use it for producing publication quality 2D maps that do not have much tweaking for your publication.
20+
A typical use case of `wrfplot` would be to include as part of your WRF model run framework
21+
to plotting of variables immediately after the model run is completed.
22+
The other use case would be
23+
to use it for producing publication quality 2D maps that have little tweaking for your publication.
1024

1125
!!! note
1226

13-
`wrfplot` is a new application. If you find any issues related to plotting variables or documentation, please open an issue in Github as given in [Support](support.md ) secion.
27+
`wrfplot` is a new application. If you find any issues related to plotting variables or documentation, please open an issue in Github as given in [Support](support.md) secion.
1428

1529

1630
The best way to explore the application is to read and execute the extensive examples provided in [usage](usage.md) section.
1731

1832
For complete list of options, execute the following command in the terminal or cmd window:
1933

20-
```console
21-
$ wrfplot --help
34+
```commandline
35+
wrfplot --help
2236
```
2337

2438
## Source Code
2539

2640
`wrfplot` is an Open Source application and released under General Public License (GPL) Version 3.
27-
The source code of the application can be found at [https://github.com/wxguy/wrfplot](https://github.com/wxguy/wrfplot).
41+
The source code of the application can be found at [https://github.com/wxguy/wrfplot](https://github.com/wxguy/wrfplot).
42+

docs/install.md

+10-10
Original file line numberDiff line numberDiff line change
@@ -3,18 +3,18 @@
33
This section briefly guides you to install **_wrfplot_** on a variety of Operating Systems viz., Linux, Windows and macOS.
44

55
## System Requirements
6-
Here are the following dependencies you should know about before installing wrfplot:
6+
Here are the following dependencies you should know about before installing `wrfplot`:
77

88
* Operating System (Windows): Windows 10 or above. May work on Windows 7/ 8 but not tested.
99

10-
* Operating System (Linux): Ubuntu 18.04 or above. If you wish to use it on Red Hat or Cent OS based, then it should be versioned 7 or above.
10+
* Operating System (Linux): Ubuntu 20.04 or above. If you wish to use it on Red Hat or Cent OS based, then it should be versioned 8 or above.
1111

1212
* Architecture: x86_64 or simple called 64bit. **_Don't download if you have 32bit machine_**. It won't work.
1313

1414
## Install on Windows, Linux and macOS
1515

1616
Support for all platforms is provided through conda-forge.
17-
If you have already conda installed, then the following command is enough to install wrfplot:
17+
If you have already conda installed, then the following command is enough to install `wrfplot`:
1818

1919
```commandline
2020
conda install -c cond-forge wrfplot
@@ -78,10 +78,10 @@ That’s it. You have successfully installed `wrfplot`.
7878

7979
### Installation under Linux
8080

81-
Go to [https://github.com/wxguy/wrfplot/releases](https://github.com/wxguy/wrfplot/releases) and look for the latest release. The Linux installer will have name wrfplot-linux-64bit.run. Click on the link and download it to local disk. Thereafter, execute the below command (assuming that the Linux installer is downloaded at ~/Downloads):
81+
Go to [https://github.com/wxguy/wrfplot/releases](https://github.com/wxguy/wrfplot/releases) and look for the latest release. The Linux installer will have name `wrfplot`-linux-64bit.run. Click on the link and download it to local disk. Thereafter, execute the below command (assuming that the Linux installer is downloaded at ~/Downloads):
8282

83-
```console
84-
$ bash ~/Downloads/wrfplot-linux-64bit.run
83+
```commandline
84+
bash ~/Downloads/wrfplot-linux-64bit.run
8585
```
8686

8787
that would produce the output as indicated below:
@@ -103,15 +103,15 @@ Installation completed. Please restart your terminal to continue using wrfplot..
103103

104104
There is no binary distribution made available for macOS at the moment. The support for macOS is provided through miniconda. If you already have miniconda/ anaconda installed, you can execute the following to install `wrfplot`:
105105

106-
```console
107-
$ conda install -c conda-forge wrfplot
106+
```commandline
107+
conda install -c conda-forge wrfplot
108108
```
109109

110110
## Confirm Installation
111111

112112
The easiest way to check the installation is to issue the following command in the terminal:
113113

114-
```console
114+
```commandline
115115
wrfplot --help
116116
```
117117

@@ -154,5 +154,5 @@ options:
154154
© J Sundar, wrf.guy@gmail.com, 2024
155155
```
156156

157-
If you get inbuilt help page of wrfplot, then it is ensured that you have successfully installed wrfplot.
157+
If you get the inbuilt help page of `wrfplot`, then it is ensured that you have successfully installed `wrfplot`.
158158

docs/license.md

+7-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
1-
wrfplot is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or any later version.
1+
`wrfplot` is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License
2+
as published by the Free Software Foundation, either version 3 of the License, or any later version.
23

3-
wrfplot is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
4+
`wrfplot` is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty
5+
of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
6+
See the GNU General Public License for more details.
47

5-
You should have received a copy of the GNU General Public License along with wrfplot. If not, see <http://www.gnu.org/licenses/>.
8+
You should have received a copy of the GNU General Public License along with `wrfplot`.
9+
If not, see <http://www.gnu.org/licenses/>.

docs/support.md

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
If you encounter any bugs or issues that have not been reported yet, you must open an issue at [https://github.com/wxguy/wrfplot/issues](https://github.com/wxguy/wrfplot/issues).
1+
If you encounter any bugs or issues that have not been reported yet, you must
2+
open an issue at [https://github.com/wxguy/wrfplot/issues](https://github.com/wxguy/wrfplot/issues).
23

34
For any other questions or inquiries, feel free to reach out to the project developer(s):
45

docs/usage.md

+22-21
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
## Basic Usage
22

3-
The first step in plotting diagnostic variable to find what all variables are supported by wrfplot application.
3+
The first step in plotting diagnostic variable to find what all variables are supported by `wrfplot` application.
44
This is required as the application would accept variable names only in certain string format.
55
Therefore, you should list and review the name of variable by issuing the following command in the terminal:
66

7-
```console
8-
$ wrfplot --list-vars
7+
```commandline
8+
wrfplot --list-vars
99
```
1010

1111
Invoking the above command will produce the following output:
@@ -56,16 +56,18 @@ Variable "u_cape" --> Convective Available Potential Energy ($J kg^{1}$)
5656
The above console print has two names. One with quote and the other is without.
5757
The name within quote such as "slp" is called short variable, and without a quote is called long variable.
5858
You can read through a list to take note of what parameter you want to plot.
59-
For example, if you need to plot `2m Relative Humidity`, then you need to remember the sort variable name in the first quote “” i.e, `“rh2”`.
60-
With this, we will proceed ahead to plot “rh2” variable. To plot any variable, there are minimum three arguments required to be provided.
61-
They are `--vars`, `--input` and `--output`. Details of these would be discussed later.
59+
For example, if you need to plot `2m Relative Humidity`, then you need to remember the sort variable name in the first
60+
quote `“”` i.e, `“rh2”`. With this, we will proceed ahead to plot “rh2” variable. To plot any variable,
61+
there are minimum three arguments required to be provided. They are `--vars`, `--input` and `--output`.
62+
Details of these would be discussed later.
6263

6364
## Plotting Surface Variable
6465

65-
All the variables which does not start with `u_` string are surface variable. Now, let's go ahead and start plotting the variable “2m Relative Humidity” named as “rh2”:
66+
All the variables which does not start with `u_` string are surface variable.
67+
Now, let's go ahead and start plotting the variable `“2m Relative Humidity”` named as `“rh2”`:
6668

67-
```console
68-
$ wrfplot --vars "rh2" --input ../../test/wrfout_data/wrfout_d01_2021-05-13_00_00_00 --output ../../test/wrfout_data/output_images
69+
```commandline
70+
wrfplot --vars "rh2" --input ../../test/wrfout_data/wrfout_d01_2021-05-13_00_00_00 --output ../../test/wrfout_data/output_images
6971
```
7072

7173
Where:
@@ -102,13 +104,13 @@ The plotted output for variable will look like below:
102104

103105
## Plotting Upper Atmospheric Variables
104106

105-
`wrfplot` supports a few upper atmospheric variables. These variables are indicated with u_ tag for ease of identification.
107+
`wrfplot` supports a few upper atmospheric variables. These variables are indicated with `u_` tag for ease of identification.
106108
By default, the plot for upper atmospheric variables would be plotted for `925`, `850`, `700`, `600`, `500`, `400`, `300` & `200` hPa.
107109
The upper levels can be controlled using `--ulevels` though.
108110
If you want to plot upper winds, you can specify the variable with the following command:
109111

110-
```console
111-
$ wrfplot --vars "u_winds" --input ../../test/wrfout_data/wrfout_d01_2021-05-13_00_00_00 --output ../../test/wrfout_data/output_images
112+
```commandline
113+
wrfplot --vars "u_winds" --input ../../test/wrfout_data/wrfout_d01_2021-05-13_00_00_00 --output ../../test/wrfout_data/output_images
112114
```
113115

114116
<figure markdown="span">
@@ -122,8 +124,8 @@ When plotting upper level variable, `wrfplot` will plot all the predefined level
122124
You can control the level at which variable is required to be plotted using `--ulevels` argument.
123125
For example, if you need to plot at `800` and `750` hpa levels only, then you can apply the following command:
124126

125-
```console
126-
$ wrfplot --vars "u_winds" --ulevels "800,750" --input ../../test/wrfout_data/wrfout_d01_2021-05-13_00_00_00 --output ../../test/wrfout_data/output_images
127+
```commandline
128+
wrfplot --vars "u_winds" --ulevels "800,750" --input ../../test/wrfout_data/wrfout_d01_2021-05-13_00_00_00 --output ../../test/wrfout_data/output_images
127129
```
128130

129131
Remember that the level values are to be separated by `,`. That should produce the following output in the terminal:
@@ -161,8 +163,8 @@ Plotting process completed. It took 0H:0M:6.948402S
161163

162164
You can also create an animation of your plots using `--gif` option. Example command is given below:
163165

164-
```console
165-
$ wrfplot --vars "rh2" --gif --input ../../test/wrfout_data/wrfout_d01_2021-05-13_00_00_00 --output ../../test/wrfout_data/output_images
166+
```commandline
167+
wrfplot --vars "rh2" --gif --input ../../test/wrfout_data/wrfout_d01_2021-05-13_00_00_00 --output ../../test/wrfout_data/output_images
166168
```
167169

168170
This would produce an animated `gif` image as shown below:
@@ -176,8 +178,8 @@ This would produce an animated `gif` image as shown below:
176178

177179
By default, the speed of the animation is kept as `0.5` sec. If you wish to increase or decrease the speed, you can do so by with `--gif-speed` option as indicated below where speed is increased to `0.25` sec:
178180

179-
```console
180-
$ wrfplot --vars "rh2" --gif --gif-speed 0.25 --input ../../test/wrfout_data/wrfout_d01_2021-05-13_00_00_00 --output ../../test/wrfout_data/output_images
181+
```commandline
182+
wrfplot --vars "rh2" --gif --gif-speed 0.25 --input ../../test/wrfout_data/wrfout_d01_2021-05-13_00_00_00 --output ../../test/wrfout_data/output_images
181183
```
182184

183185
This would increase the speed of animation as shown in the sample image file.
@@ -196,8 +198,8 @@ Levels are to be in ascending order and separated by ','.
196198
For example, `24,26,28,30,32,34,36`.
197199
Example plot to change temperature level to highlight the temperature range of interest will be as follows:
198200

199-
```console
200-
$ wrfplot --vars "rh2" --clevels '0,10,20,30,32,34,36,38,40,42,44,46' --input ../../test/wrfout_data/wrfout_d01_2021-05-13_00_00_00 --output ../../test/wrfout_data/output_images
201+
```commandline
202+
wrfplot --vars "rh2" --clevels '0,10,20,30,32,34,36,38,40,42,44,46' --input ../../test/wrfout_data/wrfout_d01_2021-05-13_00_00_00 --output ../../test/wrfout_data/output_images
201203
```
202204

203205
After executing the command with `--clevels` argument, the plot would look like this:
@@ -213,4 +215,3 @@ this can be compared with the default clevels set by the `wrfplot` as shown belo
213215
![Image title](static/images/T2_13-05-2021_17_30.png)
214216
<figcaption>T2 Plot with Default `--clevels` Option</figcaption>
215217
</figure>
216-

docs/variable-list.md docs/variables.md

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
# Supported Variables
22

3-
This page contains the list of supported variables by wrfplot. You can see the same list from your terminal by invoking `wrfplot --list-vars` command any time. The variable name starting with `u_` is upper atmospheric data at standard Pressure levels `925`, `850`, `700`, `600`, `500`, `400`, `300` and `200`. How to use the variable name (first column) will be discussed in the next page.
3+
This page contains the list of supported variables by wrfplot. You can see the same list from your terminal by
4+
invoking `wrfplot --list-vars` command any time. The variable name starting with `u_` is upper atmospheric data at
5+
standard pressure levels of `925`, `850`, `700`, `600`, `500`, `400`, `300` and `200` hPa. How to use the variable
6+
name (first column) will be discussed in the next page.
47

58
| Name of Variable | Description with unit |
69
|:------------------:|:----------------------------------------------:|

mkdocs.yml

+3-3
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,11 @@ site_author: 'J Sundar'
55
site_url: https://wxguy.github.io/wrfplot
66

77
# Repository
8-
repo_name: 'wrfplot/wrfplot'
8+
repo_name: 'wxguy/wrfplot'
99
repo_url: 'https://github.com/wxguy/wrfplot'
1010

1111
# Copyright
12-
copyright: 'Copyright 2024 J Sundar'
12+
copyright: 'Copyright &copy; 2024 J Sundar'
1313

1414
# Markdown extensions
1515
markdown_extensions:
@@ -46,7 +46,7 @@ theme:
4646
nav:
4747
- Home: index.md
4848
- Installation: install.md
49-
- Variables : variable-list.md
49+
- Variables : variables.md
5050
- Usage: usage.md
5151
- Colormaps: colormaps.md
5252
- Support: support.md

0 commit comments

Comments
 (0)