Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add transformer functions between periods #13

Open
VEZY opened this issue Dec 22, 2022 · 1 comment
Open

Add transformer functions between periods #13

VEZY opened this issue Dec 22, 2022 · 1 comment
Labels
enhancement New feature or request

Comments

@VEZY
Copy link
Member

VEZY commented Dec 22, 2022

We should be able to convert e.g. a TimeStepTable with hourly time steps into daily time steps.

Something close to:

convert(TimeStepTable{Atmosphere{Dates.Day}}, ts)

But for this we first need to be able to process the TimeStepTable{Atmosphere}:

  • identify if the time steps are daily (equal or more) or hourly (equal or more)
  • if they are hourly (or so) and need daily, check if we have a full day length (sum of durations in the same day == 24 Hour) or if there are gaps, in which case we either make a gap-filling or return an error
  • if they are daily, downscale to the required temporal scale.
  • we also have to identify if time steps are homogeneous in the TimeStepTable{Atmosphere}, if not apply the above differently between them

Downscaling (e.g. daily time steps into hourly or less or more) is pretty straightforward for known default variables (e.g. T or P), but not for unknown variables, so we should define a way for the user to provide transformations for those using e.g. DataFrames.jl syntax. And same for upscaling (e.g. hour to daily), because we don't know if we have to sum or average unknown variables.

@VEZY VEZY added the enhancement New feature or request label Dec 22, 2022
@VEZY
Copy link
Member Author

VEZY commented Feb 14, 2023

A first take on upscaling ca n be found in to_daily.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant