```r
library(dplyr)
habitat$total_area_ha<-round(st_area(habitat)/10000,1)
dif$core_area_ha<-round(st_area(dif)/10000,1)

habitat %>% st_set_geometry(NULL) -> d1
dif %>% st_set_geometry(NULL) -> d2

left_join(d1,d2, by = "mhabitat") %>% DT::datatable()
```

<!--html_preserve--><div id="htmlwidget-94baf05875295fb9a0b8" style="width:100%;height:auto;" class="datatables html-widget"></div>
<script type="application/json" data-for="htmlwidget-94baf05875295fb9a0b8">{"x":{"filter":"none","data":[["1","2","3","4","5","6","7","8"],["No main habitat but additional habitats present","Coastal saltmarsh","Reedbeds","Mudflats","Deciduous woodland","Maritime cliff and slope","Lowland dry acid grassland","Lowland heathland"],[122.8,5.4,10.5,0,65.4,1.1,4,338.2],[65.1,5.2,9.7,0,38.8,1,1.2,167.6]],"container":"<table class=\"display\">\n  <thead>\n    <tr>\n      <th> <\/th>\n      <th>mhabitat<\/th>\n      <th>total_area_ha<\/th>\n      <th>core_area_ha<\/th>\n    <\/tr>\n  <\/thead>\n<\/table>","options":{"columnDefs":[{"className":"dt-right","targets":[2,3]},{"orderable":false,"targets":0}],"order":[],"autoWidth":false,"orderClasses":false}},"evals":[],"jsHooks":[]}</script><!--/html_preserve-->