Nathan Bell-4 wrote:
>
> image = np.histogram2d(x, y, bins=bins, weights=z)[0]
>
This works great - thanks!
Thomas
--
View this message in context:
http://www.nabble.com/Rasterizing-points-onto-an-array-tp23808494p23820216.html
Sent from the Numpy-discussion mailing list archive at Nabble.c
On Sun, May 31, 2009 at 8:39 PM, Thomas Robitaille
wrote:
> Hi,
>
> I have a set of n points with real coordinates between 0 and 1, given
> by two numpy arrays x and y, with a value at each point represented by
> a third array z. I am trying to then rasterize the points onto a grid
> of size npix*
Hi,
I have a set of n points with real coordinates between 0 and 1, given
by two numpy arrays x and y, with a value at each point represented by
a third array z. I am trying to then rasterize the points onto a grid
of size npix*npix. So I can start by converting x and y to integer
pixel co