Options
Overview
1: Basics
2: Mutational Analysis
3: Correlation
4: Positive Selection
5: Ancestral States
6: Morphology Priors

Tutorial 3: Correlation

In this tutorial we will use the sample file called croc.xml. The sample files are contained in the Sample Files included with the software distribution. Red dots with lines in the images indicate the areas refered to.

A. OPEN THE FILE: (Figure 1) Open the file by selecting File->Open... and then navigate to the Sample Files folder and open croc.xml file. Once the file has been read you should see the following window open (Figure 1):

         Figure 1.



Close the window (Cmd-W). The next step is to define the standard/morphology models for the characters to be analyzed. In this tutorial we will be examining the mutational history of characters 1 and 7.

B. OPEN CONFIGURE MODELS: (Figure 2) Open the Models window by selecting Analysis->Configure Model... (Cmd-1).

(1) Select the Morphology/Std tab if not already selected (see Figure 2).

         Figure 2.



C. CONFIGURE MODEL FOR CHAR 1: (Figure 3) Character 1 is a two-state character.

(1) Select character 1 in the Character table at the left of the window (Figure 3).

(2) Select the Beta distribution prior radio button. (Four options exist for 2-state characters, see here for more details on morphology/standard models). The beta prior uses a beta distribution on the two-state frequencies. The distribution's shape is is described the parameter alpha and because it is discretized the number of categories (k) can be selected. For this tutorial we will leave alpha and k at the default values. (See here for more details on priors.)

(3) Finally, increase the number of categories used for the Gamma distribution prior to 90.

         Figure 3.



D. CONFIGURE MODEL FOR CHAR 7: (Figure 4) Character 7 is a three-state character.

(1) Select character 7 in the Character table at the left of the window (Figure 4).

(2) Select the Empirical prior radio button. (Four options exist for 2-state characters, see here for more details on morphology/standard models). The empirical prior uses the frequencies of each state in the data file for character 1.

(3) Finally, increase the number of categories used for the Gamma distribution prior to 90.

         Figure 4.



E. CLOSE THE MODELS WINDOW: At this point we are finished configuring the models for character 1 and 7 so go ahead and close the window.

F. CONFIGURE ANALYSIS: (Figure 5 & 6) Open the Analysis window by selecting Analysis->Configure Analysis... (Cmd-2).

(1) Select the Character association (correlation) radio button if it is not already selected.

(2) Since we are analyzing characters 1 and 7 only select all of the other characters and exclude them from the analysis by highlighting the desired characters and pressing the Exclude button.

         Figure 5.



Next, we have the option of choosing the number samples, which trees, and which parameters to use in the analysis. In a morphological/standard analysis the parameter options do not apply. To set these options select the Sampling tab (Figure 6).

(1) The number of samples determines how many mutational maps are simulated for each tree (and parameter) and each character included in the analysis. The number of samples selected will depend on a number of factors, such as the number of trees, total replicates desired, and the amount of patience you have. For this tuturial let's change Number of samples from 10 to 5.

(2) The number of prior draws applies only to morphological/standard analyses. This setting changes the number of draws from the prior for each replicate - it is essentially a way of exploring the prior distributions more thoroughly, rather than a single draw repeated a number of times. Let's change the Number of prior draws from 10 to 5.

(3) In order to detrmine statistical significance we will select Perform predictive sampling. More information on posterior predictive can be found here.

(4) Since we will be using predictive sampling we need to select the number of predictive samples. Change the text field Number of predictive samples from 10 to 5.

(5) Trees and parameters can be changed through options in the region highlighted in red. You can select to Use all trees (or parameters) or to select Use trees numbered to select a subset of trees in the file. Trees and parameters are numbered sequentially from the first in the file, to the last. In this tutorial we will be using all 4 trees available in the file so no changes are necessary.

         Figure 6.



One final note. When performing an analysis of molecular data one additional option is available: Link parameter order to tree order. This option by default links a tree with each parameter (e.g., 1 with 1, 2 with 2, etc.). If your trees and parameters are derived from samples from a posterior distribution (e.g., from MrBayes or an equivalent type of program) then it is recommened to leave this option active. When this option is set to be inactive, or "unlinked", be aware that every possible tree and parameter combination is evaluated and can substantially increase the analysis time.

G. CLOSE THE ANALYSIS WINDOW: At this point we are finished configuring the analysis so go ahead and close the window.

H. START THE ANALYSIS: We are now ready to run the analysis. This can be done by selecting Analysis->Run Analysis... (Cmd-R). At this point you should observe the progress indicator letting you know how long before the run will be finished. You may want to get a cup of coffee while it runs.

I. REVIEW THE RESULTS: (Figure 7) Now that the analysis is complete let's look at the results by opening the Correlation Statistics window by selecting Statistics->Morphology->Correlation Statistics.... Select the Morphology tab if it is not currently selected. To select the results for each comparison simply select the desired comparison in the Site-Site table on the left in the window.

         Figure 7.



Each of the columns in the table (from left to right) are described briefly below:

  1. Statistic: Two statistics are reported: M and D. These represent the overall correlation between two characters. For each of these a number (depending on the number of states for each character) state-by-state statistics are reported. For more on these statistics see here.
  2. Observed Value: This is the observed value for each statistic.
  3. P Value: The predictive probability that an association as extreme as that observed could arise simply by chance.
  4. Obs N: The observed sample size.
  5. Pred N: The sample size used for calculating each predictive expectation.

J. SAVE THE RESULTS TO A FILE:

To save the results of an analysis simply select Save Results... button at the lower right corner of the window. Next select a location and file name and select the Save button. The output saves the bipartition table and the results by clade and character.

K. OVERVIEW OF OTHER OPTIONS AVAILABLE DURING AN ANALYSIS

  1. Save Individual Statistics: Individual (i.e., from each mutational sample) correlation statistics can be saved during the analysis. To activate this option select Save individual statistics to file radio button in the General tab of the Analysis window and the use the Set. button to select a name and location for the file.
  2. Save Summary Statistics: Summary (i.e., across all mutational samples) correlation statistics can be saved during the analysis. To activate this option select Save summary statistics to file radio button in the General tab of the Analysis window and the use the Set. button to select a name and location for the file.
  3. Save Correlation Mappings To File: During the analysis each map of the correlation between each character comparison can be saved to a file. To activate this option select Save mutational maps to file radio button in the General tab of the Analysis window and the use the Set. button to select a name and location for the file.
  4. Save Individual Predictive Statistics: Individual (i.e., from each mutational data set) predictive correlation statistics can be saved during the analysis. To activate this option select Save predictive statistics to file radio button in the General tab of the Analysis window and the use the Set. button to select a name and location for the file.
  5. Save Predictive Correlation Mappings To File: During the analysis each map of the correlation for each predictive simulation between each character comparison can be saved to a file. To activate this option select Save predictive maps to file radio button in the General tab of the Analysis window and the use the Set. button to select a name and location for the file.