Hi everyone,
I have a dataset with 4 columns,
Product count Year Customer
1 25 2020 A
2 10 2020 B
2 20 2019 A
2 35 2019 B
1 22 2018 A
2 18 2018 B
Year
Ranges from 2015 to 2020, count
is a standard integer number.
I could like to filter out products for all Years where the average 2020 count is higher than the average 2020 count. Something like this
If mean ```count``` where ```Year``` == 2020 > mean(count) delete row and for all of the same product in the previous years.
I hope this question makes sense.
Thanks