FREQCOR_Sel_general.FREQCOR_Sel_general

FREQCOR_Sel_general.FREQCOR_Sel_general(Icon_raw, Rcon_raw, Icosp_raw, meteo_df, WS, WD, Ustar, Zeta, FlagF_H, FlagF_g, FlagVM_T, FlagVM_w, FlagVM_g, flag_wd, config)[source]

Apply general filtering to all (co)spectra and associated meteorological series.

The routine removes time steps with missing meteorology/fluxes and excludes wind direction sectors configured in config[‘USER_LIMITS’]. Invalid columns in (co)spectral matrices are set to NaN.

Parameters:
  • Icon_raw (pandas.DataFrame) – Ideal content (raw) and real content (raw) (either cospectra or spectra; depends on sps), and ideal cospectra for CF (raw) with shape [nfreq, nspec].

  • Rcon_raw (pandas.DataFrame) – Ideal content (raw) and real content (raw) (either cospectra or spectra; depends on sps), and ideal cospectra for CF (raw) with shape [nfreq, nspec].

  • Icosp_raw (pandas.DataFrame) – Ideal content (raw) and real content (raw) (either cospectra or spectra; depends on sps), and ideal cospectra for CF (raw) with shape [nfreq, nspec].

  • meteo_df (pandas.DataFrame) – Meteorological and flux time series table with length nspec.

  • WS (pandas.Series) – Wind speed, wind direction, friction velocity, and stability parameter.

  • WD (pandas.Series) – Wind speed, wind direction, friction velocity, and stability parameter.

  • Ustar (pandas.Series) – Wind speed, wind direction, friction velocity, and stability parameter.

  • Zeta (pandas.Series) – Wind speed, wind direction, friction velocity, and stability parameter.

  • FlagF_H (pandas.Series) – Mauder & Foken (2004) quality flags for sensible heat flux and gas flux.

  • FlagF_g (pandas.Series) – Mauder & Foken (2004) quality flags for sensible heat flux and gas flux.

  • FlagVM_T (array-like) – Vickers & Mahrt (1997) quality flags for temperature, vertical wind speed, and gas concentration.

  • FlagVM_w (array-like) – Vickers & Mahrt (1997) quality flags for temperature, vertical wind speed, and gas concentration.

  • FlagVM_g (array-like) – Vickers & Mahrt (1997) quality flags for temperature, vertical wind speed, and gas concentration.

  • flag_wd (pandas.Series or numpy.ndarray) – Additional wind-direction flag (ETC/ICOS Vitale). Values equal to 2 are excluded.

  • config (configparser.ConfigParser) – Run configuration. Uses: - USER_LIMITS.wdmin, USER_LIMITS.wdmax - PROCEDURE_OPTIONS.gss

Returns:

  • Icon_sel, Rcon_sel, Icosp_sel (pandas.DataFrame) – Filtered ideal content (sel) and real content (sel) (either cospectra or spectra; depends on sps), and ideal cospectra for CF (sel) with shape [nfreq,nspec].

  • meteo_df (pandas.DataFrame) – Filtered meteorological/flux table.

  • WS, WD, Ustar, Zeta (pandas.Series) – Filtered time series.

  • FlagF_H, FlagF_g, FlagVM_T, FlagVM_w, FlagVM_g (numpy.ndarray) – Filtered quality flags (converted to float arrays).

Notes

Wind direction exclusion is applied as follows: - if wdmin <= wdmax: exclude (wdmin, wdmax) - else: exclude (wdmin, 360) and (0, wdmax) (wrap-around)

Data with missing sensible heat flux (FlagF_H == -9999) is set to NaN.