Longest Winter Periods Above Freezing

I was a bit surprised that there isn’t more time periods in winter that are above freezing, but then again the climate normals for Albany are still quite warm, so such runs are uncommon to this days.

Longest Winter Periods Above Freezing
Number of days when the low temperature was 32 degrees or above from December 21 – March 21.
Days Start End
10 Mon, Mar 12, 2012 Wed, Mar 21, 2012
10 Fri, Jan 13, 1995 Sun, Jan 22, 1995
10 Mon, Mar 7, 1983 Wed, Mar 16, 1983
10 Tue, Feb 17, 1981 Thu, Feb 26, 1981
9 Tue, Feb 23, 2010 Wed, Mar 3, 2010
9 Sat, Mar 10, 1990 Sun, Mar 18, 1990
7 Wed, Jan 18, 2017 Tue, Jan 24, 2017
7 Mon, Dec 21, 2015 Sun, Dec 27, 2015
7 Thu, Mar 15, 1945 Wed, Mar 21, 1945
6 Wed, Mar 16, 2022 Mon, Mar 21, 2022
6 Mon, Mar 9, 2020 Sat, Mar 14, 2020
6 Sun, Mar 13, 2016 Fri, Mar 18, 2016
6 Wed, Feb 23, 2000 Mon, Feb 28, 2000
6 Tue, Feb 20, 1996 Sun, Feb 25, 1996
6 Wed, Feb 15, 1984 Mon, Feb 20, 1984
6 Fri, Mar 2, 1979 Wed, Mar 7, 1979
6 Sat, Mar 16, 1968 Thu, Mar 21, 1968
5 Thu, Feb 23, 1961 Mon, Feb 27, 1961
5 Wed, Feb 28, 2018 Sun, Mar 4, 2018
5 Thu, Mar 11, 2010 Mon, Mar 15, 2010
5 Sun, Mar 4, 1973 Thu, Mar 8, 1973
5 Tue, Jan 6, 1998 Sat, Jan 10, 1998
5 Fri, Dec 22, 1972 Tue, Dec 26, 1972
5 Fri, Mar 6, 1992 Tue, Mar 10, 1992
5 Sun, Feb 18, 1951 Thu, Feb 22, 1951
5 Fri, Dec 27, 1940 Tue, Dec 31, 1940
Andy Arthur, 2/6/23.
Data Source: National Weather Service Records, June 1938 to Present, Albany Airport.

This data can be obtained from the National Climate Data online. An easy way to extract this data and create the table would be to use the new version of dplyr with group_by(consecutive_id(FIELD)).

library(tidyverse)
library(lubridate)
library(gt)

wx <- read_csv('~/Downloads/3059447.csv')

wx %>% 
  mutate(
    NumericDate = month(DATE)*100 + day(DATE),
    AboveFreezing = (TMIN > 31 & (NumericDate < 322 | NumericDate > 1220))) %>%
  select(DATE, AboveFreezing) %>%
  group_by(consecutive_id(AboveFreezing)) %>%
  summarise(days = n(), AboveFreezing = first(AboveFreezing), start = first(DATE), end = last(DATE)) %>%
  filter(AboveFreezing) %>%
  select(Days = days, Start = start, End = end) %>%
  slice_max(Days, n=20) %>%
  arrange(-Days, rev(Start)) %>%
  gt() %>%
  tab_header('Longest Winter Periods Above Freezing','Number of days when the low temperature was 32 degrees or above from December 21 - March 21.') %>%
  tab_footnote(html('Andy Arthur, 2/6/23.<br /><em>Data Source:</em> National Weather Service Records, June 1938 to Present, Albany Airport.')) %>%
  opt_stylize(style=3, color = 'red') %>%
  opt_row_striping() %>%
  fmt_date(2:3,date_style="yMMMEd") %>%
 gtsave('/tmp/AboveFreezing.html')

Leave a Reply

Your email address will not be published. Required fields are marked *