Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: remove negative carryover output for weibull_pdf #706
- weibull_pdf creates lagged peak and thus negative carryover, because the previous carryover = total - raw, and with lagged peaks, total adstocked spend might be lower than raw spend. The new calculation doesn't take raw spend as immediate anymore, but derives immediate from the actual lagged decay matrix. This restores the relationship of total = carryover + immediate with all positive values. - This is the 3rd code snippets change (robyn_response) that impacts the csv output. Other other two in transformation.R and allocator.R were fixed previously. Will look into funtionalizing the 3 places.
- Loading branch information