I have data in the form:
|Date |Overdrawn|
|20/09/2018|1 |
|21/09/2018|1 |
|24/09/2018|0 |
|25/09/2018|1 |
|26/09/2018|1 |
I need to sum the number of overdrawn days with the following rule:
Missing dates (weekends) should be treated the same as the last date available.
i.e. If overdrawn on Friday, Saturday and Sunday should be counted as 2 days overdrawn. If Friday is not overdrawn, Saturday and Sunday should also be treated as not overdrawn.
In the example above date 20, 21, 22, 23, 25, 26 should be treated as overdrawn and the sum should return 6.
Can someone explain how to extrapolate the overdrawn value for the missing dates before summing?
Thanks