This function generates a random pattern of points
  in a ``stratified random'' sampling design. It can be useful
  for generating random spatial sampling points.  The bounding rectangle of win is divided into
  a regular $nx \times ny$ grid of rectangular tiles.
  In each tile, k random points are generated independently
  with a uniform distribution in that tile. 
  Some of these grid points may lie outside the window win:
  if they do, they are deleted.
  The result is a point pattern inside the window win.
  This function is useful in creating dummy points for quadrature
  schemes (see quadscheme) as well as in simulating
  random point patterns.