September 25, 2016
Frequently Asked Questions about Mplus on Mac OS X
Question: Where is Mplus installed?
Answer: In Version 6.12, the default installation location is /Applications/Mplus. In Version 6.11, the default installation location is /Users/myaccount/Applications/mplus6.11. To determine the location of the Mplus executable, open the Terminal app and type the following command
The which command will print the location of the mplus executable.
Question: How do I find out which Mplus version I have?
Answer: Open the Terminal app and type the following command
Note that there is a space between "mplus" and "-version" but no spaces between the hyphen and "version". "-version" is one word. The Mplus version will be printed to the screen.
Question: Can Mplus run on Mac OS X Lion?
Answer: Yes, Mplus can run on Mac OS X Lion, the latest version of Mac OS X.
Question: Are Mplus examples provided with the Mplus installation?
Answer: Yes, the Mplus examples are stored in the Examples folder in the Mplus folder under Applications.
Question: How do I access a second hard drive or a networked drive in the Mplus Editor?
Answer: To access a second hard drive or a networked drive, go to "Macintosh HD" in the Open file dialog. Then choose "Volumes". From there, all hard drives and networked drives should be listed and can be selected.
Question: When running Mplus on Mac OS X from the command line, the output file still says "Mplus Version 6.11" even though I have installed Mplus Version 6.12.
Answer: Installation of Mplus Version 6.12 does not automatically uninstall Version 6.11. You must go to the folder for Version 6.11 and run the "uninstall_mplus" app. If Version 6.11 is not uninstalled, then this will cause a conflict with Version 6.12 when running Mplus from the command line.
Question: Mplus fails to read the data I have converted from SPSS or Excel. Why?
Answer: When Mplus fails to read a data file that has been converted to an ASCII file from SPSS or Excel on Mac OS X, the most common cause of the problem is the end-of-line character sequence. Mac OS X uses the LF end-of-line sequence. Linux/Unix operating systems use the CR end-of-line sequence. Windows operating systems use the CRLF end-of-line sequence. Mplus can read CR or CRLF end-of-line sequence but not LF end-of-line sequence used by Mac OS X.
To determine if this is the cause of the Mplus data reading error, open the file on a Windows operating system and use Notepad to open the file. If all lines look like they have been combined into one long line, then this is an indication that the file has the LF end-of-line sequence. You can also look at this file using the more command in the Terminal window. If there are many ^M characters visible, then the file has LF end-of-line sequence. Here is an example of the more command:
The more command displays one full screen of the file at a time. Press the q key to quit more or spacebar to advance to the next page.
In the Terminal window, you can convert the file to a file with the correct line ending using perl. Type the following command at the Terminal prompt:
perl -pi -e 's/\r/\n/g' mydata.dat
Note that the file will be overwritten and no message will be printed when the process finishes. You should make a copy of the file before executing this command. Use the more command again to view the file to see if the ^M characters remain.
Question: The Mac OS X tutorial refers to mplus_setup.inp, but I can't find that file. How do I run Mplus from the command line?
Answer: The mplus_setup.inp referred to in the tutorial is just a placeholder. You need to replace this file with the name of the input file you want to run. To run Mplus on the command line, type the following command
replacing filename with the name of your input file. For example, to run Mplus on example ex3.1.inp, you would type
Question: How do I open a Terminal window?
Answer: The Terminal app can be found in the Utilities folder under Applications.
Question: How do I change directory in the Terminal app?
Answer: Use the cd command as follows
replacing folder with the name of the folder/directory you want to change to.
Question: How do I view Mplus plots on the Mac?