RGeostat function for moving window statistics?

Here you can suggest new features to be added to RGeostats package.

RGeostat function for moving window statistics?

Postby markm0705 » Fri Sep 06, 2019 12:04 am

Is there an RGeostat function for moving-window statistics that can be applied to a 2D or 3D grid or irregualry spaced data?
markm0705
 
Posts: 22
Joined: Sun Mar 17, 2019 9:39 am

Re: RGeostat function for moving window statistics?

Postby Didier Renard » Fri Sep 06, 2019 11:24 am

I have a 2-fold answer depending on what is YOUR definition of a moving window

1) If the moving window has a fixed extension, you can try db.stat.grid() which calculates any statistical feature (mean, variance, ...) from your input Db into a grid resulting Db (that I call dbgrid for clarity).
This means that you can calculate the mean (for example) of your target variable for all samples contained in a grid cell.
But you may argue that this is not exactly a MOVING neighborhood.

2) The second possibility is to use the definition of the Moving Neighborhood object of RGeostats instead. But there is no tool for answering exactly your problem for ANY statistical feature. If you are only interested by the mean of the variable (of this moving neighborhood), you can run a (Simple) Kriging by choosing a specific Model (e.g. a pure nugget effect). A s matter of fact, you remember that the result of Kriging with pure nugget effect is exactly the same operator as moving (unweighted) average.

I keep your mail as we can imagine to create a new function with arguments similar to db.stat.grid() which would use a Neighborhood object as argument. It would then offer the possibility of calculating all the statistical features as in db.stat.grid()
Didier Renard
 
Posts: 337
Joined: Thu Sep 20, 2012 4:22 pm


Return to Global suggestions

Who is online

Users browsing this forum: No registered users and 7 guests

cron