Learn R Programming

DNAseqtest (version 1.0)

Fmatrix: Joint Distribution for Two Matched Sequences

Description

This function calculates the joint distribution function for two edge tree.

Usage

Fmatrix(t1, t2, f0, Sx2, Sy2, Pix, Piy)

Arguments

t1
represents the length from the tree root to the first node
t2
represents the length from the tree root to the second node
f0
the initial distribution for the four nucleotides
Sx2
a 4 x 4 symmetric matrix related to the first edge
Sy2
a 4 x 4 symmetric matrix related to the second edge
Pix
a diagonal matrix for the stationary distribution of the first edge
Piy
a diagonal matrix for the stationary distribution of the second edge

Value

Details

This function calculates the joint distribution function for a two edge tree with different edge lengths, stationary distributions and differentS matrices.

References

Faisal Ababneh, Lars S Jermiin, Chunsheng Ma, John Robinson (2006). Matched-pairs tests of homogeneity with applications to homologous nucleotide sequences. Bioinformatics, 22(10), 1225-1231.

See Also

gn, Smatrix

Examples

Run this code
f0<-c(.25,.25,.25,.25)
Pi1<-diag(c(.2,.2,.2,.4))
Pi2<-diag(c(.1,.1,.1,.7))
S1<-Smatrix(c(.2,.2,.2,.2,.2,.2),diag(Pi1))
S2<-Smatrix(c(.3,.3,.3,.3,.3,.3),diag(Pi2))
fm<-Fmatrix(1, .5, f0, S1, S2, Pi1, Pi2)
fm

Run the code above in your browser using DataLab