R – Sum rows from different column based on condition in grouped values I have a large dataset of different sites inside and out of Natura 2000 network.