You can view this FAQ as a movie using the Real Media player, among others.
We have created a program called stata2mlwin that you can use to convert your Stata program into an MLwiN program that you can run to create a MLwiN data file.
Note that stata2mlwin now creates an additional variable called cons which is a column of 1s, which can be used for including a constant in the equations window in MLwiN (unless you already have such a variable or specify the nocons option).
You can download stata2mlwin by typing findit stata2mlwin (see
How can I use the findit command to search for programs and get additional
help? for more information about using findit).
Say we want to convert the a file called c:\data\hsb2.dta to an MLwiN data file. After installing stata2mlwin, you would type this.
stata2mlwin using c:\data\hsb2
Then you would start MLwiN and click Data Manipulation then Command Interface and then enter the wipe command and then obey c:\data\hsb2.obe (substituting c:\data\hsb2.obe with the name of your file). This then reads the data into MLwiN (including variable names and value labels).
We can then click on Data Manipulation then Names to see the names of the variables to check to see if they were read in properly.
We can then click File then Save Worksheet As... and then save this data file as a MLwiN data file.
The content of this web site should not be construed as an endorsement of any particular web site, book, or software product by the University of California.