File: divergence.html

package info (click to toggle)
lamarc 2.1.10.1%2Bdfsg-3
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 77,052 kB
  • sloc: cpp: 112,339; xml: 16,769; sh: 3,528; makefile: 1,219; python: 420; perl: 260; ansic: 40
file content (113 lines) | stat: -rw-r--r-- 7,262 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
<!-- header fragment for html documentation -->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<HTML>
<HEAD>

<META NAME="description" CONTENT="Estimation of population parameters using genetic data usi
ng a maximum likelihood approach with Metropolis-Hastings Monte Carlo Markov chain importanc
e sampling">
<META NAME="keywords" CONTENT="MCMC, Markov chain, Monte Carlo, Metropolis-Hastings, populat
ion, parameters, migration rate, population size, recombination rate, maximum likelihood">

<TITLE>LAMARC Documentation:
Modeling Linkage Properties and Relative Mutation Rates of Your Data</title>
</HEAD>


<BODY BGCOLOR="#FFFFFF">
<!-- coalescent, coalescence, Markov chain Monte Carlo simulation, migration rate, effective
 population size, recombination rate, maximum likelihood -->

<P>(<A HREF="migration_matrix.html">Back</A> | <A HREF="index.html">Contents</A>
| <A HREF="panels.html">Next</A>)</P>
<h2>Divergence</h2>

<p>
<em>(Note: it is recommended that you be familiar with the material
in the <a href="converter.html">data file conversion</a>
section before reading this section.)</em>
</p>

<p>
Divergence allows you to define the relationships between populations by linking populations pairwise into parent (or ancestor) populations. This Divergence linkage is defined on the <tt>Data Partitions</tt> tab. Once that is complete, the user can go to the <tt>Migration Matrix</tt> tab to edit the migration matrix.
</p>
<p>
Note: Because you are defining the relationship between pairs of populations and their parent, the process is iterative. You pick the first pair, the software links them to their parent, and then you pick the next pair. Thus there is a bit of back and forth between screens until you get all the connections defined. We would like to have done this graphically, but, given the constraints of the current interface, that was not possible. This interface is, quite frankly, a stop gap that saves you from editing the XML code directly (something you definitely don't wish to do). It's a bit clunky, but it does work and it has error checking.  
</p>

<h3><a name="div_def">Divergence Definition</a></h3>
<p>
Here is the <tt>Data Partitions</tt> tab for a 3 population data set before divergence is turned on. Note that the content of the <tt>Divergence</tt> button is &quot;Off&quot;.
</p>
<p><img src="batch_converter/images/DivergeOff.png" alt="Divergence off Data Partitions"/>
</p>
<p>
Picking the <tt>Divergence</tt> button yields the following screen:
</p>
<p><img src="batch_converter/images/FirstParent.png" alt="Parent_1 with no children checked"/>
</p>
<p>
There are two things that can be done here:
<ul>
<li>
<tt>Rename Parent</tt> allows you to edit the parent name. You should be aware that the XML parser that will eventually read the output from this converter into LAMARC gets confused by spaces in names, so they are automatically replaced with underscores. The software is not being perverse, it is protecting you from an unsophisticated parser.
</li>
<li>
<tt>Pick Children</tt> This is a list of all the populations that currently do not have parents. Parents can only have 2 children, so after you check two the rest will gray out. If you make a mistake, just pick the incorrect one again, it will uncheck, and the rest of the names will become active again. <tt>Unselect All</tt> will uncheck all the children. Not much of a gain in this case, but if there were 4 or 5 children it is useful.
</li>
</ul>
</p>
<p><img src="batch_converter/images/FirstParent2Children.png" alt="Parent_1 with 2 children checked"/>
</p>
<p>
Now that the first parent is chosen, the <tt>Data Partitions</tt> tab now looks like this. Note that the <tt>Divergence</tt> button now reads &quot;Continue&quot; and there is a <tt>parent</tt> cell bridging the &quot;North&quot; and &quot;South&quot; populations with the name &quot;Parent_1&quot;. 
</p>
<p><img src="batch_converter/images/InterumParentImage.png" alt="Parent_1 with 2 children image"/>
</p>
<p>
One puzzler is if you looked at the <tt>Migration Matrix</tt> tab you would find only the migration matrix between the populations and no sign of &quot;Parent_1&quot;. This is because the Divergence structure is not yet fully defined, so the Migration Matrix does not know what to do.
</p>
<p>
In order to finish the Divergence definition it is necessary to pick the Divergence button again. This time the resulting screen looks like:
</p>
<p><img src="batch_converter/images/SecondParent.png" alt="Parent_2 with 2 children checked"/>
</p>
<p>
As there are only two items lacking a parent at this point, both &quot;East&quot; and &quot;Parent_1&quot; are automatically checked. One can still edit the name, of course. 
</p>
<p>
Accepting  &quot;Parent_2&quot; leads to the fully populated Divergence <tt>Data Partitions</tt> tab with the <tt>Divergence</tt> button reading &quot;Done&quot;
</p>
<p><img src="batch_converter/images/FullParentsImage.png" alt="Full Divergence Parent set image"/>
</p>
<p>
By the way, if this was all a horrible mistake, just pick the <tt>Divergence</tt> button again and it will shut Divergence off and delete all the parent information.
</p>

<h3><a name="divmig_matrix">Divergence-Migration Matrix</a></h3>

<p>
When Divergence definition is done the <tt>Migration Matrix</tt> tab displays the Divergence-Migration Matrix. It has an identical form to the Migration Matrix except there are now rows and columns for the parent populations. If you had done any edits in the Migration Matrix before turning Divergence on, they will still be present. And if you turn Divergence off, the edits in the Population part of the matrix will not change, though the Parent part of the matrix will be lost. 
</p>
<p>
[Technical note: Divergence-Migration is actually a different Force from Migration. This is probably irrelevant to the average user but has serious internal consequences for the software.]
</p>
<p><img src="batch_converter/images/DivMigMatrixTab.png" alt="Divergence-Migration Matrix"/></p>
<p>
One thing that looks different about the Divergence-Migration Matrix is there are &quot;invalid&quot; cells off the diagonal. This is because it is impossible to have migration between populations if they don't exist at the same time. In this case, &quot;North&quot; and &quot;South&quot; are children of &quot;Parent_1&quot; and thus do not exist until &quot;Parent_1&quot; disappears. 
</p>
<p>Also note that the matrix has &quot;invalid&quot; in the entire bottom row and last column. This is because there are no other populations defined after the final parent &quot;Parent_2&quot; is defined, so migration cannot occur. Conceptually one could leave &quot;Parent_2&quot; off the matrix, but this format makes clear what is going on and is consistent with the Migration Matrix for a single population, which has a single &quot;invalid&quot; cell in it.
</p>
<p>
<a href="migration_matrix.html#edit_mat_cell">Editing the individual cells</a> is exactly the same as the Migration Matrix discussed previously. 
<p>


<P>(<A HREF="migration_matrix.html">Back</A> | <A HREF="index.html">Contents</A>
| <A HREF="panels.html">Next</A>)</P>

<!--
//$Id: divergence.html,v 1.3 2012/03/14 22:07:54 jmcgill Exp $
-->
</BODY>
</HTML>