network_groups
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| network_groups [2015/12/01 09:17] – hkimscil | network_groups [2015/12/02 14:31] (current) – hkimscil | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| ====== Identifying groups of networks ====== | ====== Identifying groups of networks ====== | ||
| + | '' | ||
| + | |||
| < | < | ||
| library(sna) | library(sna) | ||
| Line 516: | Line 518: | ||
| {{fmh.clique.5members.png? | {{fmh.clique.5members.png? | ||
| + | |||
| + | |||
| + | < | ||
| + | edge.list = matrix ( c(1, | ||
| + | s[edge.list]=1 | ||
| + | s | ||
| + | rownames(s)< | ||
| + | colnames(s)< | ||
| + | > s | ||
| + | </ | ||
| + | < | ||
| + | > edge.list = matrix ( c(1, | ||
| + | > s[edge.list] = 1 | ||
| + | > s | ||
| + | [,1] [,2] [,3] [,4] [,5] | ||
| + | [1,] 0 1 1 0 0 | ||
| + | [2,] 0 0 0 1 1 | ||
| + | [3,] 0 0 0 1 1 | ||
| + | [4,] 0 0 0 0 1 | ||
| + | [5,] 0 0 0 1 0 | ||
| + | </ | ||
| + | |||
| + | {{network_s.png? | ||
| + | |||
| + | 눈으로 봐서 a를 중심으로 좌우동형이므로 b, c와 d,e는 각각 등치 (등가)라고 할 수 있다. 이를 수식으로 구하기 위한 접근 방법으로는 연결을 1, 비연결을 0으로 한 각 노드(점) 간의 거리를 구하여 거리가 가까운 것들을 모아 놓으면 될 것이다. 가장 흔한 예가 Hamming distance: | ||
| + | * see [[yt> | ||
| + | |||
| + | 예: | ||
| + | |||
| + | |||
| + | < | ||
| + | set.seed(123) | ||
| + | p1< | ||
| + | p2< | ||
| + | G1< | ||
| + | G2< | ||
| + | G<-G1*G2 | ||
| + | G | ||
| + | |||
| + | hamming.G=sedist(G, | ||
| + | cluster <- equiv.clust(G, | ||
| + | |||
| + | |||
| + | b.mdoel <- blockmodel(G, | ||
| + | b.model | ||
| + | plot(b.model) | ||
| + | </ | ||
| + | |||
| + | {{cluster.dendrogram.png? | ||
| + | |||
| + | < | ||
| + | > b.model | ||
| + | |||
| + | Network Blockmodel: | ||
| + | |||
| + | Block membership: | ||
| + | |||
| + | | ||
| + | | ||
| + | |||
| + | Reduced form blockmodel: | ||
| + | |||
| + | |||
| + | Block 1 Block 2 Block 3 Block 4 Block 5 | ||
| + | Block 1 | ||
| + | Block 2 | ||
| + | Block 3 | ||
| + | Block 4 | ||
| + | Block 5 | ||
| + | > plot(b.model) | ||
| + | </ | ||
| + | {{blockmodel.png? | ||
| + | |||
network_groups.1448930877.txt.gz · Last modified: by hkimscil
