Opened 12 years ago

Closed 12 years ago

#1874 closed defect (fixed)

latitudinal bias in sample points created with r.random

Reported by: pvanbosgeo Owned by: grass-dev@…
Priority: major Milestone: 7.0.0
Component: Raster Version: svn-trunk
Keywords: r.random Cc:
CPU: x86-64 Platform: Linux

Description

Point patterns generated with r.random show a strong latitudinal bias, with considerably higher density at higher latitudes.

The attached screenshot illustrates this. It shows the sum of number of points in a moving window (21x21 - created with r.neighbors.

This is fairly serious because especially at lower sample densities, one may not always notice this bias, thus introducing unknowingly such bias in analysis.

Note that points created with v.random do no show a bias. However, this is not really an alternative for creating random points within a irregular area.

Attachments (1)

AEA_001.jpg (183.7 KB ) - added by pvanbosgeo 12 years ago.

Download all attachments as: .zip

Change History (8)

comment:1 by martinl, 12 years ago

Component: DefaultRaster
Keywords: r.random added

by pvanbosgeo, 12 years ago

Attachment: AEA_001.jpg added

comment:2 by pvanbosgeo, 12 years ago

I just checked, and for sample points layers generated with r.random in grass 6.4.3 there is not noticeable bias.

in reply to:  2 comment:3 by mmetz, 12 years ago

Replying to pvanbosgeo:

I just checked, and for sample points layers generated with r.random in grass 6.4.3 there is not noticeable bias.

Trunk should be fixed in r54956.

Markus M

comment:4 by pvanbosgeo, 12 years ago

I can confirm the problem is solved, the clear bias has disappeared. Thanks! Can this be marked as fixed?

in reply to:  description comment:5 by hamish, 12 years ago

Replying to pvanbosgeo:

Note that points created with v.random do no show a bias. However, this is not really an alternative for creating random points within a irregular area.

the v.random.cover addon script for grass 6 exists to do that.

http://grasswiki.osgeo.org/wiki/AddOns/GRASS_6#v.random.cover

v.random.cover is a shell script for creating random points constrained within an irregularly shaped vector area. (v.random places points only in current region rectangle). Optionally the user can upload raster values at the points. See also 'r.random cover= vector_output='

It's internal method is not especially efficient, but it gets the job done all the same.

Hamish

comment:6 by hamish, 12 years ago

It's internal

(a friend was terrible with apostrophes and to/too/two & after too many emails it begins to look natural and the bad habit has rubbed off on me! argh!)

comment:7 by pvanbosgeo, 12 years ago

Resolution: fixed
Status: newclosed

This was fixed by Markus M, so marking it as such

Note: See TracTickets for help on using tickets.