Simple interpolation / surface plane R 3d

I know this has been reviewed many times, but I just cant seem to hug him. Hopefully someone can explain in more detail the steps I need to go through to reach the surface in R.

I have a set of [x, y, z] points that I would like to turn into a surface plot. From reading around, I see that I will need to interpolate with Kring or something like that. I have absolutely no experience in 3d interpolation, so if someone could add, how would I interpolate from a set of points in 3D space, which would be a huge help.

As soon as I have this dataset, I would like to create a surface area above it. From what I understand, I can use the interp () function to do this, but again I'm not quite sure how to do this.

If there is another post that you think has already answered this question, please direct me to it.

early!

+8
r
source share
1 answer

Use the akima package. It has an interp function, which is pretty simple.

 library(akima) x <- rnorm(20) y <- rnorm(20) z <- rnorm(20) s <- interp(x,y,z) 

Once you have the interpolated matrix, you can do many things.

One example is the image.plot function in the fields package.

 image.plot(s) 
+13
source share

All Articles