Learn R Programming

WSGeometry (version 1.2.1)

grid_positions: Generate a 2d grid in [0,1]^2 of given size.

Description

Generates a matrix containing the positions of the points of an equidistant 2d grid in [0,1]^2.

Usage

grid_positions(n, m)

Arguments

n

Integer giving one dimension of the grid.

m

integer giving the other dimension of the grid.

Value

A (nm)x2 grid containing the positions of the desired grid.