## <PostgreSQLResult>
I would assume that there would be only one territory each year. However the table shows some birds with more than one.
territories %>% group_by(MALE, year) %>% summarise(n=n()) -> d
dd<-data.frame(d)
DT::datatable(dd[,1:3])
Click on polygons for info.
## [1] TRUE