index.egonet: Compute Burt's indexes (effective size and aggregate...

Description Usage Arguments Value Author(s) References Examples

View source: R/codiciegonet.r

Description

Compute Burt's indexes (effective size and aggregate constraint) and other measure from sna package. It also allow to restrict the analysis to one social circle identified by the name of the alters.

Usage

1
index.egonet(dat, index = list("effsize", "constraint", "outdegree", "indegree", "efficiency", "hierarchy", "centralization", "gden", "ego.gden"), subset = NULL, ego.name = "EGO")

Arguments

dat

graph to be analyzed having row and column names in the same order.

index

is a list containing prespecified index functions. effsize and constraint are defined in as in Burt (1992) \ outdegree and indegree make a call of degree(dat, cmode="outdegree") and degree(dat, cmode="indegree") and take the element corresponding to ego.name\ ego.gden applies gden in a matrix without ego.name connections. \ Other indeces are call of the homonimous functions of package sna. \ If the generic element is.call(index[[h]]) is TRUE, it will be evaluated in the global environment: eval(index[[h]],envir =.GlobalEnv) (see also example below)

subset

Restricts the analysis to the nodes with at least one among the elements of vector in the name. If vector = NULL - the default - all the nodes of the graph are comprised.

ego.name

column and row name given to the ego subject. The default is EGO

Value

The requested indices.

Author(s)

A. Sciandra, F. Gioachin, L. Finos <livio@stat.unipd.it>

References

Burt, R.S. (1992) ā€¯Structural Holes. The Social Structure of Competitionā€¯, Cambridge (MA), Harvard University Press.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
# make a toy dataset
egomat <-  matrix(c(0,1,1,1,0,0,1,0,0),3,3)
colnames(egomat) <- rownames(egomat) <- c("EGO", "1P", "1A")

index.egonet(egomat)

# an example with self defined index 
my.outdegree <- function(dat) degree(dat,cmod="outdegree")[1]
index.egonet(egomat,index=c("effsize","constraint","outdegree","indegree","efficiency", "centralization", "gden", "ego.gden", my.outdegree=call("my.outdegree",dat=egomat)))

#Restricts the \code{outdegree} and \code{efficiency} to "EGO" and nodes with "P" in the name
index.egonet(egomat,index=c("outdegree","efficiency"),subset="P")

egonet documentation built on May 29, 2017, 3:27 p.m.