I created three dummy variable apple,pear and orange, and I wanted to tab the variable "list" if the dummy variable is 1:
Code:
input str10 fruit apple pear orange end levelsof fruit, local(fruit) foreach a of local fruit { tab2xl list if `a' == 1, using "test3.xls", sheet("`a'") row(1) col(1) append excel($append) }
0 Response to how to loop with tab2xl?
Post a Comment