Source
def ztec_value(my_long,my_lat,points_long,points_lat,ref_long,ref_lat,incr_long,incr_lat,incr_time,ref_start,ref_end,num_maps,tec_array,PLOT=False,PLOTNAME=''):
#!/usr/bin/env python
## =============================================================================
## =============================================================================
##
## tec_maps.py
##
## Created by J. E. Kooi 2014/04/25 v2.0
## Modified by gmoellen 2014/07/21 v2.1 (minor mods, mostly semantics)
## Modified by J. E. Kooi 2014/09/17 v2.2 (minor mods, formating and
## ~ Test for network connection
## ~ Heirarchy of IGS-related
## data products added
## ~ Added IGS RMS TEC maps
## ~ Made IGS default data product)
## Modified by gmoellen 2014/09/30 v2.3 (added simplified create method
## that hides all of the MAPGPS-related
## options, and thereby streamlines
## approved general usage for
## CASA 4.3)
## Modified by J. E. Kooi 2015/01/29 v2.4 (Changed get_IGS_TEC to accept
## IONEX format data with ANY grid
## spacing in deg. and time res in min)
## Modified by J. E. Kooi 2015/03/2 v2.5 (Changed ztec_value for doplot =
## True to plot a red bar over the VTEC
## to show the observing session)
## Modified by gmoellen 2017/05/30 v2.6 Generate plot disk file
## Modified by bkent 2017/10-31 v2.7 Fixed VisibleDeprecationWarning:
## using a non-integer
## number instead of an integer will
## result in an error in the future
## Modified by gmoellen 2020/08/28 v2.8 Updated TEC retrieval to use more-secure
## CDDIS server (ftp-ssl), as old
## service going offline 2020Oct31;
## other python cleanup
## 2020/10/13 python3-ification, for CASA 6.
##
## Tested in CASA 4.3.0 and 4.2.1 on RHEL release 6.4 (Santiago)
## Tested in CASA 4.3.0, 4.2.2, and 4.2.1 on Mac OS 10.8.5
##
##
##
## The purpose of this python module is to retrieve vertical TEC/DTEC maps from
## either IGS (housed on the CDDIS servers) or MAPGPS (housed on the Madrigal
## servers).
##
## **** Currently, the MAPGPS is "turned off" and modification of line 306 ****
## **** is required to turn this functionality back "on." ****
##
## The IGS Final Product maps represent a combined TEC map:
## The different IGS Ionosphere Associate Analysis Centers IAAC TEC maps have
## been computed with different approaches but with a common formal resolution
## of 2 hours, 5 degrees, and 2.5 degrees in UT, longitude, and latitude
## (details can be found in e.g. Schaer, 1999; Feltens, 1998;
## Mannucci et al., 1998; Gao et al.; Hernandez-Pajares et al.,1999). The four
## IAACs TEC maps have been combined in an IGS combination product using weights
## obtained by two IGS Ionosphere Associate Validation Centers (IAVCs) from the
## corresponding performances in reproducing STEC and differences of STEC (IAVCs
## NRCAN and UPC respectively, see details in Feltens, 2002).
## ------ Krankowski & Sieradzki, 2013 (references can be found in this paper)
##
## The code has a hierarchy for IGS data products. It will initially search for
## the IGS Final product data (available ~ 10-14 days after an observation) and,