comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Question about the TOTAL function.
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Question about the TOTAL function. [message #43543] Fri, 15 April 2005 08:53
Nuno Oliveira is currently offline  Nuno Oliveira
Messages: 75
Registered: October 2003
Member
I have a question that somebody that works with IDL many had faced before.
Imagine I have a matrix(X,Y), no matter the type of variable, and if want na
array with the projection along de x axis, something like



for i = 0, n-1 do $

SUMX = TOTAL(i, *)



How can I do it without the FOR cicle.



If I try



SUMX[ 0:N-1 ] = TOTAL( 0:N-1, * )



The function returns the total of the matrix for the every position of SUMX.
Is there a way that I can do it quicker?



Thanks in advance,



Greeting,



Nuno.
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Re: unit testing for IDL?
Next Topic: tvimage, imcontour and ps dimensions

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Fri Oct 10 14:13:43 PDT 2025

Total time taken to generate the page: 0.32270 seconds