Apologies in advance if this has already been asked elsewhere.
I have multiple data frames (with 25 columns and > 1000 rows) like this :
> head(Amsterdam_C02 <- Amsterdam %>% filter(Chemicals == "CO2"))
Sample_ID Locality.Name Chemicals
1 VKB19xxxxxx Amsterdam CO2
2 VKB19xxxxxx Amsterdam CO2
3 VKB1xxxxxxx Amsterdam CO2
4 VKB1xxxxxxx Amsterdam CO2
5 VKB1xxxxxxx Amsterdam CO2
6 VKB1xxxxxxx Amsterdam CO2
End.Date Less.Than Activity.Value Measuring.Unit
1 2019-01-31 < 1.0714000 g/m³
2 2019-02-18 3.4609000 g/m³
3 2019-02-28 < 0.7020623 g/m³
4 2019-04-25 4.5563282 g/m³
5 2019-05-20 1.6000000 g/m³
6 2019-05-22 < 0.6000000 g/m³
I wish to obtain the mean, max, min and sd of Activity.Value, classified by month, and taken into account the values only when Less.Than is not "<" (the "<" means the value is below the detection limit and will be not kept for statistics). This example displays one or two value(s) per month, but there are hundreds. So, R must return the 4 statistics of Activity.value each month (in a vector or whatever). If there no value above the detection limit for one specific month, then R must return "-" for the 4 statistics.
In addition, I would like that R returns the mean of all the values during the whole year (not classified per month) that have not been into account because Less.Than is "<".
I made different attempts but nothing worked correctly and I prefer to ask for your help.
If Less.Than == "<" ???
To filter per month I have already tried %>% filter(grepl("2019-01") 12 times but if possible, I prefer to avoid doing it manually because I have other data frames with similar analysis to perform on it.