Skip to content
Prev 4938 / 29559 Next

plotting Football field ball pattern data

Hi,

I was going to post a similar question as I am also a fresh new user of R.

In my case I have between 10 million and 20 million latitude,
longitude pairs and want to get an image in which each pixel has a
color that is a function of the amount of positions that would fall
into the spatial bin corresponding to the pixel size. I understand
that this would be akin to a 2D histogram of my data and resemble a
density plot.

The way I started doing that was importing the table with read.table()
and then converting it to a PPP object providing the adequate bounds.
The first problem I face is that when I try to put all the points into
the PPP object I get a memory failure.

To keep experimenting I lowered the number of points I import and
played around with the density function available in spatstat but
while I can see its uses when you have few points, in my case the
patters would get diluded very fast even for small values of sigma and
I am afraid it would not represent the data faithfully.

On the other hand the function quadratcount returns very fast results
for a high number of partitions in the X and Y axis and I could
certainly use the results it provides, if it wouldn't be for the fact
that when I try to plot it, I get the grid and the point count inside
each cell. Is there any way to convert the output of gridcount into a
colored plot in the same spirit of the one you get when you do a
plot(density())?

Hope it wasn't too confusing. As you can see I've tried to take a jab
at it on my own, but it is proving more complicated than I expected!
:)

Cheers,
Miguel

On Fri, Jan 30, 2009 at 06:09, srinivasa raghavan
<srinivasraghav at gmail.com> wrote: