Skip to content
Prev 27663 / 29559 Next

Implementing a rolling window for stars object

Hi Micha,

I can see two problems immediately with your code:
 1. you are using a double-colon (yr::last_yr) - the double colon is used for looking for an object in a package, so it is looking for object ?yrs? in package ?yr?, which obviously doesn?t make sense. Use a single colon to create a range (like you did with 2:6)
2.  the object ?last_yr? is never defined, so even if you used a single colon to define the range yr:last_yr, it would fail as it would not be able to find object ?last_yr?

Cheers,
Andy Teucher