pyrad.prod.generate_intercomp_products#

pyrad.prod.generate_intercomp_products(dataset, prdcfg)[source]#
Generates radar intercomparison products. Accepted product types:
‘PLOT_AND_WRITE_INTERCOMP_TS’: Writes statistics of radar

intercomparison in a file and plots the time series of the statistics. User defined parameters:

voltype: str

name of the pyrad variable to use, it must be available in the dataset

add_date_in_fname: Bool

If true adds the year in the csv file containing the statistics. Default False

sort_by_date: Bool

If true sorts the statistics by date when reading the csv file containing the statistics. Default False

step: float

The quantization step of the data. If none it will be computed using the Py-ART config file. Default None

rewrite: Bool

If true rewrites the csv file containing the statistics. Default False

npoints_min: int

The minimum number of points to consider the statistics valid and therefore use the data point in the plotting. Default 0

transform: str

A transform to apply to the data before computing the statistics and generating the plots. Any mathematical function with argument “x” is accepted for example “sin(x) + x**2” or “10 * log10(x)” Default is to use no transform

corr_min: float

The minimum correlation to consider the statistics valid and therefore use the data point in the plotting. Default 0.

‘PLOT_SCATTER_INTERCOMP’: Plots a density plot with the points of

radar 1 versus the points of radar 2 User defined parameters:

voltype: str

name of the pyrad variable to use, it must be available in the dataset

step: float

The quantization step of the data. If none it will be computed using the Py-ART config file. Default None

scatter_type: str

Type of scatter plot. Can be a plot for each radar volume (instant) or at the end of the processing period (cumulative). Default is cumulative

range_bins: list of floats

Range bins to radar 1 to consider, a different plot will be generated for all range bins.This can be used to differentiate the analysis in different radar ranges. Default is to generate only one figure, regardless of the distance to radar 1.

transform: str

A transform to apply to the data before computing the statistics and generating the plots. Any mathematical function with argument “x” is accepted for example “sin(x) + x**2” or “10 * log10(x)” Default is to use no transform

‘WRITE_INTERCOMP’: Writes the instantaneously intercompared data

(gate positions, values, etc.) in a csv file. User defined parameters:

voltype: str

name of the pyrad variable to use, it must be available in the dataset

‘WRITE_INTERCOMP_TIME_AVG’: Writes the time-averaged intercompared

data (gate positions, values, etc.) in a csv file. User defined parameters:

voltype: str

name of the pyrad variable to use, it must be available in the dataset

Parameters:
  • dataset (tuple) – values of colocated gates dictionary

  • prdcfg (dictionary of dictionaries) – product configuration dictionary of dictionaries

Returns:

filename (str) – the name of the file created. None otherwise