BrunaLab / HeliconiaDemography

Effects of drought and habitat fragmentation on Heliconia acuminata.
Other
0 stars 1 forks source link

SPEI history should start in year t+1 #23

Closed Aariq closed 3 years ago

Aariq commented 3 years ago

The current data wrangling creates size and size_next, which is fine, except the dates used to join the weather history are for the measurement of size. The weather history should start in the year the response (size_next) was measured and go back in time from there, not from the previous year.

Aariq commented 3 years ago

but that doesn’t make sense for flowering since flowering recorded in year t+1 happened right after the year t census. Census in Feb measures previous year's inflorescences (flowering from late Jan–Apr).

Aariq commented 3 years ago

Or survival since we don't know which month plants died in. Should death in the next year or death in the previous year be modeled a function of SPEI in the previous months?

Aariq commented 3 years ago

Talked with @embruna, and survival should be thought of as "is a plant alive now, and is that a function of size last census?". To that end, I need to change how survival is coded. Currently the surv column is "does the plant survive to the next year?". Every plant that dies at some point in the survey should have a final entry with NA for size, a value for size_prev, a 0 for surv, and the same SPEI history as for growth and flowering models.