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

Determine why Cass Lake is so much warmer than nearby similar lakes #25

Open
jordansread opened this issue Jun 8, 2020 · 3 comments
Open

Comments

@jordansread
Copy link

For Gretchen's request on GDD, I did this quick processing (DOWs were her's)

From hyperscales-data-release directory:

library(tidyverse)
dow_xwalk <- readRDS('../lake-temperature-model-prep/2_crosswalk_munge/out/mndow_nhdhr_xwalk.rds')
dows <- paste0('mndow_', c('04003000', '04003800', '04007900', '04000700', '11041500', '04004900'))
dow_xwalk %>% filter(MNDOW_ID %in% dows)
# A tibble: 6 x 2
  MNDOW_ID       site_id       
  <chr>          <chr>         
1 mndow_04000700 nhdhr_166868512
2 mndow_04003000 nhdhr_166868528
3 mndow_04003800 nhdhr_120019527
4 mndow_04004900 nhdhr_166868535
5 mndow_04007900 nhdhr_120019522
6 mndow_11041500 nhdhr_166868528 !!! OH NO same as mndow_04003000

 
predictions_df <- scipiper::scmake('predictions_df')

Gretchens_DOW_GDD_lakes <- predictions_df %>% filter(site_id %in% c('nhdhr_166868512','nhdhr_166868528','nhdhr_120019527','nhdhr_166868535','nhdhr_120019522','nhdhr_166868528')) %>%
    pull(source_filepath) %>% purrr::map(function(file) {
        feather::read_feather(file) %>% mutate(year = lubridate::year(DateTime), temp = temp_0-5, gdd_raw_temp = ifelse(temp < 0, 0, temp)) %>% group_by(year) %>%
            summarize(GDD = sum(gdd_raw_temp), site_id = basename(file))
    }) %>% purrr::reduce(bind_rows)

ggplot(data = Gretchens_DOW_GDD_lakes, aes(x = year, y = GDD, color = site_id)) +
    geom_line() +
    theme_bw() 

image

@jordansread
Copy link
Author

This is because the PB0 driver data were mixed up :(

@aappling-usgs
Copy link
Contributor

Ah ha! 💡

@jordansread
Copy link
Author

What it looks like now (and proof to @aappling-usgs that I am continuing to ggplot 😆 )

image

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

2 participants