Hi all,
I am having a problem with getting parsimony scores in Phangorn and have
found that the program is not reading in my datafile the way I expect it.
I have 10 characters and 5 taxa, but phangorn seems to read this the
opposite way round.
Can anybody help? Details follow,
thanks,
Jen
Hi Jen.
Try changing to a matrix first (from a data frame). [I.e.,
p-as.matrix(p); p2-phyDat(p,type=USER,levels=c(0,1)) ]
I'm not sure why this works, but it seems to. - Liam
More details below.
When I do:
p-matrix(c(1,0,0,0,1,0,1,0,1,0,
1,1,0,1,1,0,0,1,0,0,
1,0,0,1,0,1,0,0,1,0,
Hi Jenny,
thanks Liam. he's right. You have to change the data to a matrix.
In a data.frame all elements of a columns must contain the same data
type. When using data.frames I stored characters in the columns. This
would make it possible to allow to have binary characters in one
column and