1

I have just started to learn spatial analysis of point pattern with R.

On page 20 of this book, the "Swedishpines" dataset has been used for inspection purposes. However, I want to use my own dataset intead of this data. My dataset is a group of point features having lat and and long and a text field for the point feature. Making a SUMMARY of my dataset does not result in the following details (for swedishpines data, borrowed from the book)

> summary(X)
Planar point pattern: 71 points
Average intensity 0.0074 points per square unit (one unit = 0.1 metres)
Window: rectangle = [0, 96] x [0, 100] units
Window area = 9600 square units
Unit of length: 0.1 metres

I understand that in order to follow on the example of this book, I would first need to create a Planer Point Pattern out of this Shapefile.

How can I do that?

I tried googling but nothing came up.

  • You might want to take a look at the as.ppp() function. Are your data in a data frame? A SpatialPointDataFrame? It would be easier to give a detailed answer if you provided a sample. – cengel Jun 6 '15 at 19:52
  • I checked it and my problem is solved! Thanks for the hint! – R Lover Jun 8 '15 at 13:59
0

As pointed out by @cengel, the ppp function in spatstat package will take care of the work. Please check the following link for detailed information: http://www.inside-r.org/packages/cran/spatstat/docs/as.ppp

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.