hello everyone I am new to stata and I am stuck.
I am trying to do a simple ttest to see if my means differ significantly. However I have 12 variables that each can be broken down into 4 subcategories (ex. Netincome could be classified as NIsamestate, NIdiffstate, NIsamesector, NIdiffsector)
I want to compare those 4 against each other and do the same for all 12 variables. So far I have done this:
foreach var of varlist ni-roe{
gen new`var'=`var' if targetstate==acquirorstate
}
I did this same command 4 times creating 48 variables.
Now I want to run a ttest but I have no clue. And was there a simpler way I could have done the above command? Can anyone help?
Sincerely,
Michael
*
* For searches and help try:
* http://www.stata.com/support/faqs/res/findit.html
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/