msms Cheat Sheet


September 27, 2010
-ms nsamples nrep

The total number of samples and number of replicates.
 

-N Ne

Set Ne, note that event times are in discrete generation times in units of 4Ne. It is safe to set this very high when selection is not considered.
 

-t θ

Set the value of θ = 4Neμ
 

-T

Output gene trees.
 

-r ρ [nsites]

Set recombination rate ρ = 4Ner where r is the recombination rate between the ends of a unit length sequence. If nsites are omitted then an infinite sites recombination model is used.
 

-G α

Set growth parameter of all populations to α.
 

-I npop n1 n2 …[4Nem]

Set up a structured population model. The sample configuration must add up to the same total number of samples as specified by -ms.
 

-n i x

Set the size of subpopulation i to xNe.
 

-g i αi

Set the growth rate of subpopulation i to αi.
 

-m i j Mij

Set the (i,j) element of the migration matrix to Mij.
 

-ma M11

Set the entire migration matrix.
 

-eM t x

Set all elements of the migration matrix at time t to x∕(npop - 1)
 

-es t i p

Split subpopulation i into subpopulation i and npop+1 pastward. Each lineage currently in subpopulation i is retained with probability p, otherwise it is moved to the new population. The migration rates to the new subpopulation are zero and its population size is set to Ne.
 

-ej t i j

Join subpopulation i to subpopulation j. All migration matrix entries with subpopulation i are set to zero. The population size of i is also set to zero. With selection this population is ignored pastward from this time.
 

-e[X] t

Set some parameter pastward from time t. Here [X] can be any of G g n m ma and the meaning is defined as for the normal command, for example -en t i x sets the population size of deme i to xNe pastward from time t.
 

-l n a1 a1an an

Set the neutral loci starting and stopping positions for n loci. Note that must be ai < ai+1 for all i and that there must be 2n values. All parameters assume a sequence length of 1. This other parameter needs to be scaled accordingly.
 

-SAA 4NesAA

Set the selection strength of the homozygote.
 

-SAa 4NesAa

Set the selection strength of the heterozygote.
 

-Smu θ

Set the forward mutation rate for the selected allele in units of 4Neμ. That is the mutation from the wild type a to derived type A.
 

-Snu θ

Set the backward mutation rate for the selected allele in units of 4Neν. That is the mutation from the selected type A to the wild type a.
 

-Sp x

Set the position x in the sequence of the selected allele.
 

-Sc t i 4NesAA 4NesAa 4Nesaa

Set the selection strength in deme i to the specified values pastward from time t.
 

-SF t

Set the selection simulation stopping condition to fixation at time t pastward from sampling time. Note the demographic model must be time invariant for this option not to raise an error. It is up to the user to ensure that the parameters permit the model to always go to fixation, otherwise it will keep simulating till it runs out of memory.
 

-SI t npop x1 x2

Set the start of selection to time t forward in time from this point. The initial frequencies of the beneficial allele are x1,x2,. Note that this option is not compatible with -SF.
 

-oTPi w s [onlySummary]

Output windowed θ estimates (both Wattersons and π based estimators) and Tajima’s D with window size w and step size s. If onlySummary, then only the averages of all replicates are output. The output format is a table formatted as follows: The first column is the bin position. The second column is the Watterson’s θ estimator. The third column is the π1 estimator and the last column is Tajima’s D. The summary also contains the standard deviations for the previous data column. Thus, column 3 is the standard deviation of the Wattersons θ estimators.
 

-oOC

Output the number of origins of the beneficial allele in the sample. A count of 0 or 1 means a hard sweep if conditioned on fixation.
 

-oAFS [jAFS] [onlySummary]

Output allele frequency spectra. If the jAFS option is specified, all pairwise deme joint frequency spectra are output.