Skip to content

Commit

Permalink
EXAMPLE: update the plot_dealias example
Browse files Browse the repository at this point in the history
  • Loading branch information
jjhelmus committed Aug 18, 2016
1 parent 2d8ee55 commit 3fa4d8b
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions examples/correct/plot_dealias.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,8 @@
# read in the data
radar = pyart.io.read_mdv(RADAR_NAME)

# find and extract sonde data
target = netCDF4.num2date(radar.time['data'][0], radar.time['units'])
interp_sounde = netCDF4.Dataset(SOND_NAME)
t = pyart.correct.find_time_in_interp_sonde(interp_sounde, target)
height, speed, direction = t
# read in sonde data
dt, profile = pyart.io.read_arm_sonde_vap(SOND_NAME, radar=radar)

# create a gate filter which specifies gates to exclude from dealiasing
gatefilter = pyart.filters.GateFilter(radar)
Expand All @@ -37,8 +34,7 @@

# perform dealiasing
dealias_data = pyart.correct.dealias_fourdd(
radar, sounding_heights=height * 1000.0, sounding_wind_speeds=speed,
sounding_wind_direction=direction, gatefilter=gatefilter)
radar, sonde_profile=profile, gatefilter=gatefilter)
radar.add_field('corrected_velocity', dealias_data)

# create a plot of the first and sixth sweeps
Expand Down

0 comments on commit 3fa4d8b

Please sign in to comment.