Skip to content
Prev 27667 / 29559 Next

Implementing a rolling window for stars object

Interesting - there?s some rlang/tidy evaluation trickery going on there that I couldn?t quite figure out (I think it might be searching for yr in the wrong environment), but defining your range as a single variable, and putting that in the square brackets seems to work for me:

rng <- yr:last_yr
stars_window = ci_stars[,,,rng]