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

Can't create trajectories with daily meterology data (NAM 12, gdal0.5 etc) #68

Closed
ChrisLaw08 opened this issue Jun 7, 2021 · 1 comment

Comments

@ChrisLaw08
Copy link

Hi Richard,

Thank you for creating such a wonderful R package. I've already used it extensively, and being able to keep my workflow all in R has been such a time saver.

I've encounter this strange problem that only seems to happen with meterology data that you dowload on a daily basis like the NAM 12 and gdal0.5, but doesn't occur with the monthly data like NARR. When the model is started at UTC hours 22 or 23, no trajectory can be created. For example:

TestNAM<-hysplit_trajectory( lat = 44.3658, lon = -73.9028, height = 976, duration = 72, direction = "backward", met_type = "nam12", days = as.Date("2018-07-15"), daily_hours = 22, clean_up = FALSE )

But I get the warning:
'Warning message:
Problem with mutate() input traj_dt.
ℹ All formats failed to parse. No formats found.
ℹ Input traj_dt is `lubridate::ymd_h(date_h_str).

And it returns an empty tibble. However, when I run this same trajectory using NARR data instead, no issues seem to occur. In addition, if I run the above code for hours 21 and before, there doesn't seem to be any issues either. Any ideas what could be causing this issue? My best guess is it involes how datetimes are getting read in, but I'm not really sure.

This seems related to issue #67, which may provide some extra ideas.

Thanks for the great work you've done on this package

@ChrisLaw08
Copy link
Author

After a couple of years, I wanted to come back to this to mention that this isn't an issue with splitr but with HYSPLIT itself. For daily meteorology files like the NAM 12, you need an extra day of data for hours after 21 UTC. This problem exists in the HYSPLIT stand alone software as well. There may be a way to include this tweak in splitr, but it's simple enough to just extend your analysis an extra in R as well.

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

No branches or pull requests

1 participant