rchlumsk / RavenR

R package for handling Raven hydrologic modelling framework inputs, outputs, and diagnostics
36 stars 16 forks source link

record period overlap visualization for EC met stations (via weathercan package) #97

Closed aviolinist closed 2 years ago

aviolinist commented 2 years ago

OVERVIEW OF FIRST DRAFT This function is designed to support the data collection process when searching for climate stations operated by Environment Canada via the weathercan package. It receives outputs from the weathercan::stations_search and weathercan::weather_dl functions to compile each stations' record period onto a chronological timeline.

A bar plot counting the number of stations containing records for each given year also accompanies the output, making it easier for users to identify data-rich periods.

Also coming soon - the analogous function that accepts flow data supplied from the tidyhydat package. Example output: image

OUTSTANDING WORK/FUNCTION DESIGN DECISIONS

  1. A print statement identifying data-rich periods. This then raises the question of how many stations need to overlap for a period to be considered "data rich"?

  2. Allow user to specify a threshold - the minimum number of stations they would like in an overlapping period. This can be used to produce the print statement described in task 1 above, or perhaps allow background shading in the primary plot?

  3. Currently the primary plot makes use of geom_rect to produce the record lines. The coloring of each station's record follows the station's elevation. Simon is wondering if this is helpful as it could help speak to considerations for lapse rates and elevation bands in the model or if it should be taken out. If kept in, some thought should be given towards color gradient scheme for visibility/accessibility purposes.

  4. The standalone examples in the function header currently requires the user to download data using the weathercan package. It would be nice to have this data incorporated as part of the RavenR package sample data.