Skip to content

v0.73.0

Compare
Choose a tag to compare
@holukas holukas released this 17 Apr 20:59
· 118 commits to main since this release
b8a9369

v0.73.0 | 17 Apr 2024

New features

  • Added new function trim_frame that allows to trim the start and end of a dataframe based on available records of a
    variable (diive.core.dfun.frames.trim_frame)
  • Added new option to export borderless
    heatmaps (diive.core.plotting.heatmap_base.HeatmapBase.export_borderless_heatmap)

Additions

  • Added more info in comments of class WindRotation2D (diive.pkgs.echires.windrotation.WindRotation2D)
  • Added example data for EddyPro full_output
    files (diive.configs.exampledata.load_exampledata_eddypro_full_output_CSV_30MIN)
  • Added code in an attempt to harmonize frequency detection from data: in class DetectFrequency the detected
    frequency strings are now converted from Timedelta (pandas) to offset (pandas) to .freqstr. This will yield
    the frequency string as seen by (the current version of) pandas. The idea is to harmonize between different
    representations e.g. T or min for minutes. Currently it seems that pandas is not consistent with e.g. the
    represenation of minutes, using T in .infer_freq() but min
    for Timedelta (
    see here). (diive.core.times.times.DetectFrequency)

Changes

  • Updated class DataFileReader to comply with new pandas kwargs when
    using .read_csv() (diive.core.io.filereader.DataFileReader._parse_file)
  • Environment: updated pandas to v2.2.2 and pyarrow to v15.0.2
  • Updated date offsets in config filetypes to be compliant with pandas version 2.2+ (
    see here and here), e.g., 30T was changed
    to 30min. This seems to work without raising a warning, however, if frequency is inferred from available data,
    the resulting frequency string shows e.g. 30T, i.e. still showing T for minutes instead
    of min. (diive/configs/filetypes)
  • Changed variable names in WindRotation2D to be in line with the variable names given in the paper by Wilczak et
    al. (2001) https://doi.org/10.1023/A:1018966204465

Removals

  • Removed function timedelta_to_string because this can be done with pandas to_offset().freqstr
  • Removed function generate_freq_str (unused)

Tests

  • Added test case for reading EddyPro full_output
    files (tests.test_loaddata.TestLoadFiletypes.test_load_exampledata_eddypro_full_output_CSV_30MIN)
  • Updated test for frequency detection (tests.test_timestamps.TestTime.test_detect_freq)

What's Changed

Full Changelog: v0.72.1...v0.73.0