Page 1 of 1
Get subranges?
Posted: Tue Nov 25, 2014 10:01 pm
by linear feedback
I can use GET SUBSCRIPTS to read in subscripts but how can I add or map subranges to it if the names of subscripts are not known in advance?
Re: Get subranges?
Posted: Wed Nov 26, 2014 12:03 pm
by Administrator
Can you upload a simple model demonstrating what mapping you need to do? There may be a way to do it.
Re: Get subranges?
Posted: Wed Nov 26, 2014 11:52 pm
by linear feedback
I'd like to map the subranges in column B to the range in A. Trouble is that the number of elements in the subrange categories can change and should adjust itself to the data sets. Any thoughts?
Re: Get subranges?
Posted: Thu Nov 27, 2014 9:05 am
by Administrator
Can you work with these files?
Read in the subscripts as before, but create a cross reference matrix. Then use this as a multiplier to convert
Re: Get subranges?
Posted: Fri Nov 28, 2014 3:50 pm
by linear feedback
Thank you for your suggestion. As I would be dealing with 700 x 70 items a matrix does get a bit more complex in Excel. I have attached a solution which uses indexed subscripts - as one cannot calculate (especially references) with subscripts in vensim I use variables for doing so. Any thoughts which approach is better?
Is there a way around the necessity to call GET SUBSCRIPT with two fixed cell references? Using a different data set with a different structure requires also changing the model which a user won't like doing.
Re: Get subranges?
Posted: Mon Dec 01, 2014 9:23 am
by Administrator
Is there a way around the necessity to call GET SUBSCRIPT with two fixed cell references? Using a different data set with a different structure requires also changing the model which a user won't like doing.
I'll raise this a feature request.
Regarding which method is better, it's really a matter of personal preference (and ease of understanding).