r-spatial / rgee

Google Earth Engine for R
https://r-spatial.github.io/rgee/
Other
677 stars 146 forks source link

rao() function from R-package rasterdiv #224

Closed dpoursanidis closed 1 year ago

dpoursanidis commented 2 years ago

Hello amazing team!

You are doing wonderfull developments.

I have a question/request.

I wanna run the Rao() function from the R-package rasterdiv at "EarthEngine Object: Image". How can that be done? Any plans to include rasterdiv in the developements?

csaybar commented 2 years ago

Hi @dpoursanidis thanks for your words of encouragement!

I never use rasterdiv, can you provide more details about what the function does exactly? I think would be a better feature for rgeeExtra.

dpoursanidis commented 2 years ago

Hi @csaybar.

The function does "In other words, Rao's Q is the expected difference in reflectance values between two pixels drawn randomly with replacement from the considered evaluated pixels set. The distance matrix can be built in several dimensions (layers), thus allowing to consider more than one band at a time" from https://www.sciencedirect.com/science/article/pii/S1470160X16304319.

We usually use NDVI or other spectra indices to calculate Rao Q index and is used as a sarrogate for the estimation of the structure and functions of vegetated habitats (forests, meadows, marshes, etc.) and the α & β diversity of plants in a given area.

The values are from 0 to 4/5 and the higher the value the higher the diversity. By comparing with a reference year/time, we can also further estimate if changes occur and if these are statistical significant.