Running in Command-Line Mode

MEGA is distributed with two user interfaces: a full graphical user interface (GUI) and a command-line interface (MEGA-CC). The command-line interface requires a special input file called a MEGA Analysis Options (.mao) file which specifies the analysis to run as well as the analysis options to use. This .mao file can only be created by using the GUI interface. This example will show how to generate a .mao file with the graphical interface and then use that file to analyze a data set with MEGA-CC.

 

Generating the MEGA Analysis Options File

On the main MEGA window, click the Prototype button, which is near the bottom right corner of the window, to switch MEGA to the prototyping mode. A dialog will be shown that prompts for the data type to be used. In this

dialog, select Nucleotide and click OK.

Select Phylogeny | Construct/Test Neighbor-Joining Tree from the main MEGA windows launch bar.

The Analysis Preferences window will be shown. We will use the default options so in this dialog, just click the Save Settings button.

When prompted to save the .mao file, navigate to your Documents\MEGA X\Examples folder and save the file as infer_NJ_nucleotide.mao.

Close MEGA X.

Launching MEGA-CC from a command shell

Open a command shell and use the cd command to change to your Documents\MEGA X\Examples directory.

In the command shell, execute the following command:

megacc -a infer_NJ_nucleotide.mao -d Drosophila_Adh.meg -o demo

MEGA-CC will run the Phylogeny | Construct/Test Neighbor-Joining Tree analysis using the Drosophila_Adh.meg sequence alignment (located in the Examples directory) and output two files - a newick file (demo.nwk) with the newly created phylogeny and a text file (demo_summary.txt) that contains a summary of the analysis. The same steps are also used to execute any of the other analyses that are available in megacc. To see

the options that are available when using megacc, enter the following command in a command shell:

megacc -h