Hi I am a relative novice in CR so should be grateful for any help.
I have three fields from my database: the month, fees for each month and number of members for each month. I want to try to index the month via some integer i, say, so that Jan 2000 = 1, Feb 2000 = 2, etc. My fees for each month are then F(i) and the number of members is M(i). Using these arrays I then have to calculate certain quantities which depend on summing up the previous twelve months' figures. For example, one quantity is the sum of the previous 12 months fees, call this R(i), so that
R(i) = sum_{j=0}^{j=11) F(i-j).
In words: the sum from j=0 to j=11 of F(i-j).
Does anyone know of a way which uses arrays and some loop which would allow me to do this? My experience of arrays especially is not what it should be.
Many thanks for your help.
I have three fields from my database: the month, fees for each month and number of members for each month. I want to try to index the month via some integer i, say, so that Jan 2000 = 1, Feb 2000 = 2, etc. My fees for each month are then F(i) and the number of members is M(i). Using these arrays I then have to calculate certain quantities which depend on summing up the previous twelve months' figures. For example, one quantity is the sum of the previous 12 months fees, call this R(i), so that
R(i) = sum_{j=0}^{j=11) F(i-j).
In words: the sum from j=0 to j=11 of F(i-j).
Does anyone know of a way which uses arrays and some loop which would allow me to do this? My experience of arrays especially is not what it should be.
Many thanks for your help.