Displaying 2 results from an estimated 2 matches for "coocurrencies".
Did you mean:
concurrencies
2010 Nov 10
3
create a pairwise coocurrence matrix
...ppearing in a number of documents. For example I have the following table
with binary values showing the presence or absence of a certain term in a
document:
term1 term2 term3 term4 term5 doc1 1 1 0 0 1 doc2 1 1 0 1 1 doc3 1 0 0
0 1
And I want to have a matrix with the number of the pairwise coocurrencies.
So, based on the above table the matrix should be:
term1 term2 term3 term4 term5 term1 0 2 0 1 3 term2 2 0 0 1 2 term3 0 0
0 0 0
term4
1 1 0 0 1
term5
3 2 0 1 1
Any ideas on how to do that?
Tahnks
Tax
[[alternative HTML version deleted]]
2009 Oct 26
1
zeros keep dropping
Hello All!
I am trying to plot the frequency of species coocurrance.
If given a data set similar like this...(V1="species A", V2="species B",
V3="frequency of cooccurance")
> data
V1 V2 V3
1 A B 0
2 A C 2
3 A D 5
4 B C 0
5 B D 1
6 C D 0
> data1<-as.data.frame(lapply(data,function(x)(rep(x,data$V3))))
> as.data.frame(data1[-1])
>