Kriging

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Kriging

DINESHKUMAR
how to create prediction grid like meuse grid
*Thanks & Regards*

*C Dineshkumar*
*Bsc Agriculture*
*M.Tech Remote Sensing and GIS*

        [[alternative HTML version deleted]]

______________________________________________
[hidden email] mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Reply | Threaded
Open this post in threaded view
|

Re: Kriging

Erin Hodgess-2
Hi!

If you have a Spatial Points Data Frame, you can use the following function
to create a grid:

create1 <- function(obj) {

# Function that creates a new_data object if one is missing

        convex_hull = chull(coordinates(obj)[,1],coordinates(obj)[,2])

        convex_hull = c(convex_hull, convex_hull[1]) # Close the polygon

        d = Polygon(coordinates(obj)[convex_hull, ])

        new_data = spsample(d, 20, type = "regular")

        gridded(new_data) = TRUE

        return(new_data)

}



Hope this helps!


Sincerely,

Erin




Erin Hodgess, PhD
mailto: [hidden email]


On Fri, May 17, 2019 at 8:01 AM DINESHKUMAR <[hidden email]>
wrote:

> how to create prediction grid like meuse grid
> *Thanks & Regards*
>
> *C Dineshkumar*
> *Bsc Agriculture*
> *M.Tech Remote Sensing and GIS*
>
>         [[alternative HTML version deleted]]
>
> ______________________________________________
> [hidden email] mailing list -- To UNSUBSCRIBE and more, see
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide
> http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>

        [[alternative HTML version deleted]]

______________________________________________
[hidden email] mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.