String arguments to @cumsum
Posted: Fri Sep 06, 2013 5:45 am
Hi,
I have a programming niggle that I'm hoping someone on here can help with.
I have several dates saved as strings:
I need to use the function @cumsum within a loop, using various combinations of the above dates as the sample restriction for @cumsum.
The problem I'm having is that @cumsum requires the sample to be entered as a single string inside double quotes. I know that I can get around the problem by first defining a separate string for each sample range I need:
but, due to the number of different samples I need, this is not a very elegant solution to my problem.
Any ideas??
I have a programming niggle that I'm hoping someone on here can help with.
I have several dates saved as strings:
Code: Select all
%snap1="2013Q4"
%snap2="2014Q4"
'etc etc
The problem I'm having is that @cumsum requires the sample to be entered as a single string inside double quotes. I know that I can get around the problem by first defining a separate string for each sample range I need:
Code: Select all
%smpl1=%snap1 + " " + %snap2 'etcAny ideas??