« first day (1834 days earlier)      last day (1689 days later) » 

07:07
Hi all :-)
morning
 
1 hour later…
08:25
hello
 
6 hours later…
14:52
Morning from GMT-5.
 
1 hour later…
16:19
Invalidated the previous feedback on stackoverflow.com/a/61504789
 
4 hours later…
19:50
I have a data.frame with count and week of the year (and year). When I convert this to monthly data, things go askew. Because some months start in the middle of the week, weeks get lumped with one month or the other, but I would want to split my count proportionally to corresponding months. Is there a function that can do this for me, or am I doomed to finding out which day of the week is starting the new month and then splitting count manually between adjacent months?
    week value  year year_week  datum      year_month
   <dbl> <dbl> <dbl> <chr>      <date>     <chr>
 1     1   528  2019 2019-W01-2 2019-01-01 2019-01
 2     2   503  2019 2019-W02-2 2019-01-08 2019-01
 3     3   493  2019 2019-W03-2 2019-01-15 2019-01
 4     4   487  2019 2019-W04-2 2019-01-22 2019-01
 5     5   526  2019 2019-W05-2 2019-01-29 2019-01
For instance, first week of 2019 starts on Friday and count ot 528 should be split up into 5/7 and 2/7. This would mean that 377 would be assigned to December 2018 (week 52 or so) and 151 to January 2019 (week 1).
20:31
Solved it manually, don't waste your time reading the above.

« first day (1834 days earlier)      last day (1689 days later) »