From: Pete on 22 Dec 2009 12:40 I think I see - however, X and Y form circles of points......each column of X and Y (from left to right) roughly forms a circle of points (using positive and negative coordinates)....as the columns of coordinates go from left to right, the radii of the circles increases.........and the radii do not increase by a constant amount from column to column. Probably i am missing the point, but i can't see a way to simply add on and divide etc. to change the random walk coordinates (x,y) so that they lie between 1:nrp and map to such a spatial grid in a meaningful way. ImageAnalyst <imageanalyst(a)mailinator.com> wrote in message <ede0ad28-c333-4083-82c4-420434440c4c(a)t42g2000vba.googlegroups.com>... > Pete: > Yes I realized that. And I thought my last paragraph was the nice > "trick" that would speed it up for you. > > Why calculate the min of a huge bunch of numbers, and then compare it > to that same bunch of numbers just to find an index that you already > have? And then you do this unnecessary stuff not once, but twice. > And it's not only twice, it's twice for every one of your ten thousand > numbers - what a huge waste of time and effort for something that can > be done so simply and efficiently. > -ImageAnalyst
From: Pete on 22 Dec 2009 12:43 I think I see - however, X and Y form circles of points......each column of X and Y (from left to right) roughly forms a circle of points (using positive and negative coordinates)....as the columns of coordinates go from left to right, the radii of the circles increases.........and the radii do not increase by a constant amount from column to column. Probably i am missing the point, but i can't see a way to simply add on and divide etc. to change the random walk coordinates (x,y) so that they lie between 1:nrp and map to such a spatial grid in a meaningful way. ImageAnalyst <imageanalyst(a)mailinator.com> wrote in message <ede0ad28-c333-4083-82c4-420434440c4c(a)t42g2000vba.googlegroups.com>... > Pete: > Yes I realized that. And I thought my last paragraph was the nice > "trick" that would speed it up for you. > > Why calculate the min of a huge bunch of numbers, and then compare it > to that same bunch of numbers just to find an index that you already > have? And then you do this unnecessary stuff not once, but twice. > And it's not only twice, it's twice for every one of your ten thousand > numbers - what a huge waste of time and effort for something that can > be done so simply and efficiently. > -ImageAnalyst
From: ImageAnalyst on 22 Dec 2009 13:07 What's wrong with the way I suggested? You basically send out a bunch of random paths. Then you want to calculate a histogram of the number that stop at various radii, right? Why then have a 2D histogram? Why not just histogram along distance? If, instead, you want a histogram (count) of how many stop at each 2D coordinate (because radius alone is not enough, and you need direction also), then you can use a 2D array and use the method I suggested to increment the number that stop at each location.
From: Pete on 22 Dec 2009 13:50 Hi ImageAnalyst: What I need to do is calculate how many points stop at each 2D coordinate. Imagine the radii of the circles that X and Y produce increase like so: r = [0.1 2 13 200 7000 36000 50000.......etc], so we have a bunch of X and Y coordinates covering a whole host of magnitudes, that are non-uniformly spaced, and positive and negative. How can I obtain the index of random walk coordinates in order to map them to an X and a Y in such a radically non-uniform grid by just adding on a number and dividing by another? If that's possible, I seem to be missing a piece......... Cheers Pete ImageAnalyst <imageanalyst(a)mailinator.com> wrote in message <78bb22bc-1649-4e5a-a945-c185a5d4d75d(a)o28g2000yqh.googlegroups.com>... > What's wrong with the way I suggested? You basically send out a bunch > of random paths. Then you want to calculate a histogram of the number > that stop at various radii, right? Why then have a 2D histogram? Why > not just histogram along distance? If, instead, you want a histogram > (count) of how many stop at each 2D coordinate (because radius alone > is not enough, and you need direction also), then you can use a 2D > array and use the method I suggested to increment the number that stop > at each location.
First
|
Prev
|
Pages: 1 2 Prev: Reduce elements in a point cloud Next: Warnings engOpen - Handle Array ..., MCOS initial... |