tmesaglio / Australian-plant-photos

2 stars 1 forks source link

main driver 2 - spatial occurrence #19

Open tmesaglio opened 2 years ago

tmesaglio commented 2 years ago

@wcornwell @eflowerproject I still need to do a bit of minor cleaning of points randomly in the middle of the ocean, but here's the heat map (with thanks to Sophie for her awesome code).

image

Looks pretty good!! Three hotspots = the Top End from Broome to Arnhem Land, SW Western Australia, and the Daintree

This is at a resolution of 1 degree x 1 degree cells

wcornwell commented 2 years ago

maybe try this: https://www.rdocumentation.org/packages/CoordinateCleaner/versions/2.0-20/topics/cc_sea ?

tmesaglio commented 2 years ago

maybe try this: https://www.rdocumentation.org/packages/CoordinateCleaner/versions/2.0-20/topics/cc_sea ?

yeah I tried that (I used it to clean a few records that had coordinates in herbaria), but unfortunately removing sea records also removes all of the island records; essentially it only treats continential Australia + Tasmania as 'land', and everything else like Xmas, Norfolk, Lord Howe etc get wiped out too.

Should be pretty quick to fix manually

wcornwell commented 2 years ago

also, i'm usually not in favor of this, but this might be a good situation to split the continuous variable into bins e.g.

  1. 0 unphotographed species known
  2. 1 unphotographed species known
  3. 2-5
  4. 5-10
  5. 10-100
  6. >100

might make for easier interpretation by readers compared to the continuous scale--for example it's good for people to be able to see the difference between 0 and 1

tmesaglio commented 2 years ago

Yep no worries, can do. With those exact bins?

wcornwell commented 2 years ago

idk, might have to fiddle with the bins, but i think the difference between 0 and 1 and 1 and 10 are getting lost currently.

tmesaglio commented 2 years ago

@wcornwell new version with binned data (ignore the legend formatting, I have to fix that; the colours are correctly assigned to each bin, it's just the order that's been swapped around) image

wcornwell commented 2 years ago

Looking good! I think there are some new tricks with 'geom_raster' for discrete data to get the legend right. Will google...

wcornwell commented 2 years ago

maybe something like: https://r-graph-gallery.com/267-reorder-a-variable-in-ggplot2.html

wcornwell commented 2 years ago

@tmesaglio are you recovering from the bioblitz?

where is the code for this fig?

tmesaglio commented 2 years ago

@tmesaglio are you recovering from the bioblitz?

where is the code for this fig?

BioBlitz was fantastic, lots to tell you about

the code for that figure should be in the R file ‘driver 1 - spatial analysis’, and it’s from line 124 onwards

wcornwell commented 2 years ago

bettercolor

tmesaglio commented 2 years ago

that's very nice, very clean looking. Thoughts on the legend being reversed? Highest number at top?

wcornwell commented 2 years ago

rev_legend

tmesaglio commented 2 years ago

beautiful!

tmesaglio commented 2 years ago

@wcornwell did you have the updated code for this polished version?

wcornwell commented 2 years ago

updated code here: https://github.com/tmesaglio/Australian-plant-photos/commit/5a5923f2d6bd4f543b3e429ba1592fada6ca8ad1