From your brief description, I'm not sure why there would be several hundred rows required, but to simplify I suspect you could use the classify proc of a series: Proc/Generate by classification... from the menu, and series_name.classify using the command form.
Thank you, but it's not a matter of displaying the data in a table. I am performing microsimulations, so I don't just want to show the data, I want my EViews program to generate it randomly. And I think I should have pointed out that I'm using panel data.
I am trying to populate a series in a large panel dataset with some values, with each possible value having a uniquie probability.
The reason I could have hundreds of rows is because I could have 200 possible colors for each chair, for example. (another example, imagine I'm populating the series with the height of people and I know the probability of each height occurring, like 6% of population will be exactly 6 feet tall, 15% will be exactly 5 feet tall, etc....)
Now say I was using panel data with 10,000 cross-sections (i.e. 10,000 different chairs) and I knew the exact probability of a chair having a certain color. I would like a program that would populate my series "chair_color" using the probabilities I have.
Again, the way I'm doing it now is like this:
Code: Select all
Series b = rnd
Series a = @recode(b<0.1,1,@recode(b<0.5,2,3))
But if there were 200 possibilities (instead of just 3), it would take forever to write.
Please let me know if anything is not clear and thanks again!