Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature 2085 convert R script (pntnc2ascii.r) to python #2341

Merged
merged 24 commits into from
Nov 18, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
bb069d2
#2085 Initial release
Nov 5, 2022
6b77519
#2085 Removed debug message
Nov 5, 2022
fdb0cdf
#2085 Added skip-header option
Nov 9, 2022
2475b65
#2085 Renamed from print_nc2ascii.py and moved to scripts/utility dir…
Nov 16, 2022
76e5a2c
#2085 Renamed from print_nc2ascii.py and moved to scripts/utility dir…
Nov 16, 2022
896d89b
#2085 Added --out option
Nov 17, 2022
eda0536
#2085 Initial release
Nov 17, 2022
6b7bc6e
#2085 Added scripts/utility
Nov 17, 2022
97d650c
#2085 Added scripts/utility/Makefile
Nov 17, 2022
f3c6470
#2085 Delete pntnc2ascii.R
Nov 17, 2022
6c3c9b2
#2085 Removed pntnc2ascii.R
Nov 17, 2022
67f0278
#2085 Format obs value
Nov 17, 2022
65187e4
Updates documentation to reflect new Python utility script print_poin…
DanielAdriaansen Nov 17, 2022
170967c
#2085 Added --out option to usage
Nov 17, 2022
dbe32a6
Merge branch 'feature_2085_R_to_python_pntnc2ascii_R' of github.com:d…
Nov 17, 2022
8c683d1
Corrects path in command example, and changes heading to avoid lookin…
DanielAdriaansen Nov 17, 2022
4a9c84c
Merge branch 'feature_2085_R_to_python_pntnc2ascii_R' of github.com:d…
DanielAdriaansen Nov 17, 2022
2346b41
#2085 Corrected typo
Nov 17, 2022
9095489
Merge branch 'feature_2085_R_to_python_pntnc2ascii_R' of github.com:d…
Nov 17, 2022
82e18e5
#2085 Corrected typo
Nov 17, 2022
4c7ffd5
Corrects command to show arguments.
DanielAdriaansen Nov 17, 2022
13a2e77
Merge branch 'feature_2085_R_to_python_pntnc2ascii_R' of github.com:d…
DanielAdriaansen Nov 17, 2022
fc47956
#2285 Corrected comment
Nov 18, 2022
78a2ae9
Merge branch 'feature_2085_R_to_python_pntnc2ascii_R' of github.com:d…
Nov 18, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@

ACLOCAL_AMFLAGS = -I m4

SUBDIRS = data src scripts/Rscripts scripts/python
SUBDIRS = data src scripts/Rscripts scripts/python scripts/utility

if ENABLE_DEVELOPMENT
SUBDIRS += internal/test_util
Expand Down
5 changes: 3 additions & 2 deletions Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ ETAGS = etags
CTAGS = ctags
CSCOPE = cscope
DIST_SUBDIRS = data src scripts/Rscripts scripts/python \
internal/test_util
scripts/utility internal/test_util
am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/config.h.in INSTALL \
compile config.guess config.sub depcomp install-sh missing \
ylwrap
Expand Down Expand Up @@ -349,7 +349,8 @@ top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
ACLOCAL_AMFLAGS = -I m4
SUBDIRS = data src scripts/Rscripts scripts/python $(am__append_1)
SUBDIRS = data src scripts/Rscripts scripts/python scripts/utility \
$(am__append_1)
MAINTAINERCLEANFILES = \
Makefile.in \
aclocal.m4 \
Expand Down
3 changes: 2 additions & 1 deletion configure
Original file line number Diff line number Diff line change
Expand Up @@ -8848,7 +8848,7 @@ done

# Create configured files

ac_config_files="$ac_config_files Makefile scripts/Rscripts/Makefile scripts/Rscripts/include/Makefile scripts/python/Makefile data/Makefile data/climo/Makefile data/climo/seeps/Makefile data/colortables/Makefile data/colortables/NCL_colortables/Makefile data/config/Makefile data/map/Makefile data/map/admin_by_country/Makefile data/poly/Makefile data/poly/HMT_masks/Makefile data/poly/NCEP_masks/Makefile data/wrappers/Makefile data/ps/Makefile data/table_files/Makefile data/tc_data/Makefile src/Makefile src/basic/Makefile src/basic/enum_to_string/Makefile src/basic/vx_cal/Makefile src/basic/vx_config/Makefile src/basic/vx_log/Makefile src/basic/vx_math/Makefile src/basic/vx_util/Makefile src/basic/vx_util_math/Makefile src/libcode/Makefile src/libcode/vx_afm/Makefile src/libcode/vx_analysis_util/Makefile src/libcode/vx_color/Makefile src/libcode/vx_data2d/Makefile src/libcode/vx_data2d_factory/Makefile src/libcode/vx_data2d_grib/Makefile src/libcode/vx_data2d_grib2/Makefile src/libcode/vx_data2d_nc_met/Makefile src/libcode/vx_data2d_nc_pinterp/Makefile src/libcode/vx_data2d_nccf/Makefile src/libcode/vx_geodesy/Makefile src/libcode/vx_gis/Makefile src/libcode/vx_gnomon/Makefile src/libcode/vx_grid/Makefile src/libcode/vx_gsl_prob/Makefile src/libcode/vx_nav/Makefile src/libcode/vx_solar/Makefile src/libcode/vx_nc_obs/Makefile src/libcode/vx_nc_util/Makefile src/libcode/vx_pb_util/Makefile src/libcode/vx_plot_util/Makefile src/libcode/vx_ps/Makefile src/libcode/vx_pxm/Makefile src/libcode/vx_render/Makefile src/libcode/vx_shapedata/Makefile src/libcode/vx_stat_out/Makefile src/libcode/vx_statistics/Makefile src/libcode/vx_time_series/Makefile src/libcode/vx_physics/Makefile src/libcode/vx_series_data/Makefile src/libcode/vx_regrid/Makefile src/libcode/vx_tc_util/Makefile src/libcode/vx_summary/Makefile src/libcode/vx_python3_utils/Makefile src/libcode/vx_data2d_python/Makefile src/libcode/vx_bool_calc/Makefile src/libcode/vx_pointdata_python/Makefile src/libcode/vx_seeps/Makefile src/tools/Makefile src/tools/core/Makefile src/tools/core/ensemble_stat/Makefile src/tools/core/grid_stat/Makefile src/tools/core/mode/Makefile src/tools/core/mode_analysis/Makefile src/tools/core/pcp_combine/Makefile src/tools/core/point_stat/Makefile src/tools/core/series_analysis/Makefile src/tools/core/stat_analysis/Makefile src/tools/core/wavelet_stat/Makefile src/tools/other/Makefile src/tools/other/ascii2nc/Makefile src/tools/other/lidar2nc/Makefile src/tools/other/gen_ens_prod/Makefile src/tools/other/gen_vx_mask/Makefile src/tools/other/gis_utils/Makefile src/tools/other/ioda2nc/Makefile src/tools/other/madis2nc/Makefile src/tools/other/mode_graphics/Makefile src/tools/other/modis_regrid/Makefile src/tools/other/pb2nc/Makefile src/tools/other/plot_data_plane/Makefile src/tools/other/plot_point_obs/Makefile src/tools/other/wwmca_tool/Makefile src/tools/other/gsi_tools/Makefile src/tools/other/regrid_data_plane/Makefile src/tools/other/point2grid/Makefile src/tools/other/shift_data_plane/Makefile src/tools/other/mode_time_domain/Makefile src/tools/other/grid_diag/Makefile src/tools/tc_utils/Makefile src/tools/tc_utils/tc_dland/Makefile src/tools/tc_utils/tc_pairs/Makefile src/tools/tc_utils/tc_stat/Makefile src/tools/tc_utils/tc_gen/Makefile src/tools/tc_utils/rmw_analysis/Makefile src/tools/tc_utils/tc_rmw/Makefile"
ac_config_files="$ac_config_files Makefile scripts/Rscripts/Makefile scripts/Rscripts/include/Makefile scripts/python/Makefile scripts/utility/Makefile data/Makefile data/climo/Makefile data/climo/seeps/Makefile data/colortables/Makefile data/colortables/NCL_colortables/Makefile data/config/Makefile data/map/Makefile data/map/admin_by_country/Makefile data/poly/Makefile data/poly/HMT_masks/Makefile data/poly/NCEP_masks/Makefile data/wrappers/Makefile data/ps/Makefile data/table_files/Makefile data/tc_data/Makefile src/Makefile src/basic/Makefile src/basic/enum_to_string/Makefile src/basic/vx_cal/Makefile src/basic/vx_config/Makefile src/basic/vx_log/Makefile src/basic/vx_math/Makefile src/basic/vx_util/Makefile src/basic/vx_util_math/Makefile src/libcode/Makefile src/libcode/vx_afm/Makefile src/libcode/vx_analysis_util/Makefile src/libcode/vx_color/Makefile src/libcode/vx_data2d/Makefile src/libcode/vx_data2d_factory/Makefile src/libcode/vx_data2d_grib/Makefile src/libcode/vx_data2d_grib2/Makefile src/libcode/vx_data2d_nc_met/Makefile src/libcode/vx_data2d_nc_pinterp/Makefile src/libcode/vx_data2d_nccf/Makefile src/libcode/vx_geodesy/Makefile src/libcode/vx_gis/Makefile src/libcode/vx_gnomon/Makefile src/libcode/vx_grid/Makefile src/libcode/vx_gsl_prob/Makefile src/libcode/vx_nav/Makefile src/libcode/vx_solar/Makefile src/libcode/vx_nc_obs/Makefile src/libcode/vx_nc_util/Makefile src/libcode/vx_pb_util/Makefile src/libcode/vx_plot_util/Makefile src/libcode/vx_ps/Makefile src/libcode/vx_pxm/Makefile src/libcode/vx_render/Makefile src/libcode/vx_shapedata/Makefile src/libcode/vx_stat_out/Makefile src/libcode/vx_statistics/Makefile src/libcode/vx_time_series/Makefile src/libcode/vx_physics/Makefile src/libcode/vx_series_data/Makefile src/libcode/vx_regrid/Makefile src/libcode/vx_tc_util/Makefile src/libcode/vx_summary/Makefile src/libcode/vx_python3_utils/Makefile src/libcode/vx_data2d_python/Makefile src/libcode/vx_bool_calc/Makefile src/libcode/vx_pointdata_python/Makefile src/libcode/vx_seeps/Makefile src/tools/Makefile src/tools/core/Makefile src/tools/core/ensemble_stat/Makefile src/tools/core/grid_stat/Makefile src/tools/core/mode/Makefile src/tools/core/mode_analysis/Makefile src/tools/core/pcp_combine/Makefile src/tools/core/point_stat/Makefile src/tools/core/series_analysis/Makefile src/tools/core/stat_analysis/Makefile src/tools/core/wavelet_stat/Makefile src/tools/other/Makefile src/tools/other/ascii2nc/Makefile src/tools/other/lidar2nc/Makefile src/tools/other/gen_ens_prod/Makefile src/tools/other/gen_vx_mask/Makefile src/tools/other/gis_utils/Makefile src/tools/other/ioda2nc/Makefile src/tools/other/madis2nc/Makefile src/tools/other/mode_graphics/Makefile src/tools/other/modis_regrid/Makefile src/tools/other/pb2nc/Makefile src/tools/other/plot_data_plane/Makefile src/tools/other/plot_point_obs/Makefile src/tools/other/wwmca_tool/Makefile src/tools/other/gsi_tools/Makefile src/tools/other/regrid_data_plane/Makefile src/tools/other/point2grid/Makefile src/tools/other/shift_data_plane/Makefile src/tools/other/mode_time_domain/Makefile src/tools/other/grid_diag/Makefile src/tools/tc_utils/Makefile src/tools/tc_utils/tc_dland/Makefile src/tools/tc_utils/tc_pairs/Makefile src/tools/tc_utils/tc_stat/Makefile src/tools/tc_utils/tc_gen/Makefile src/tools/tc_utils/rmw_analysis/Makefile src/tools/tc_utils/tc_rmw/Makefile"


if test -n "$MET_DEVELOPMENT"; then
Expand Down Expand Up @@ -9736,6 +9736,7 @@ do
"scripts/Rscripts/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/Rscripts/Makefile" ;;
"scripts/Rscripts/include/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/Rscripts/include/Makefile" ;;
"scripts/python/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/python/Makefile" ;;
"scripts/utility/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/utility/Makefile" ;;
"data/Makefile") CONFIG_FILES="$CONFIG_FILES data/Makefile" ;;
"data/climo/Makefile") CONFIG_FILES="$CONFIG_FILES data/climo/Makefile" ;;
"data/climo/seeps/Makefile") CONFIG_FILES="$CONFIG_FILES data/climo/seeps/Makefile" ;;
Expand Down
1 change: 1 addition & 0 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -1183,6 +1183,7 @@ AC_CONFIG_FILES([Makefile
scripts/Rscripts/Makefile
scripts/Rscripts/include/Makefile
scripts/python/Makefile
scripts/utility/Makefile
data/Makefile
data/climo/Makefile
data/climo/seeps/Makefile
Expand Down
15 changes: 15 additions & 0 deletions docs/Users_Guide/reformat_point.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1171,4 +1171,19 @@ The configuration option listed above is common to many MET tools and are descri
This entry is an array of dictionaries, each containing a **GRIB code** string and mathcing **variable name** string which define a mapping of GRIB code to the output variable names.


Point NetCDF to ASCII Python Utility
====================================

As a tool for debugging, a utility script called print_pointnc2ascii.py is included for users. This script reads the MET point NetCDF file format and returns an ASCII representation to the screen, with either space or comma delimiting. Optionally, the user can request that the output be written to a file.

The script can be found at:

.. code-block:: none

MET_BASE/shared/met/utility/print_pointnc2ascii.py

For how to use the script, issue the command:

.. code-block:: none

python3 MET_BASE/shared/met/utility/print_pointnc2ascii.py -h
1 change: 0 additions & 1 deletion scripts/Rscripts/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ rscripts_DATA = \
plot_ensemble.R \
plot_probri.R \
plot_tcmpr.R \
pntnc2ascii.R \
trmm2nc.R \
trmmbin2nc.R

Expand Down
1 change: 0 additions & 1 deletion scripts/Rscripts/Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -365,7 +365,6 @@ rscripts_DATA = \
plot_ensemble.R \
plot_probri.R \
plot_tcmpr.R \
pntnc2ascii.R \
trmm2nc.R \
trmmbin2nc.R

Expand Down
176 changes: 0 additions & 176 deletions scripts/Rscripts/pntnc2ascii.R

This file was deleted.

33 changes: 33 additions & 0 deletions scripts/utility/Makefile.am
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
## Makefile.am -- Process this file with automake to produce Makefile.in
## Copyright (C) 2000, 2006 Gary V. Vaughan
##
## This program 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 2, or (at your option)
## any later version.
##
## This program 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.
##
## You should have received a copy of the GNU General Public License
## along with this program; if not, write to the Free Software
## Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
## MA 02110-1301, USA.

# SUBDIRS = include


## Example of how to Install outside of $(pkgdatadir)
## scriptsrootdir = $(prefix)/share/scripts
## pythonutilitydir = ${scriptsrootdir}/utility

pythonutilitydir = $(pkgdatadir)/utility

pythonutility_DATA = \
print_pointnc2ascii.py

EXTRA_DIST = ${pythonutility_DATA}

MAINTAINERCLEANFILES = Makefile.in
Loading