qpGetCliques             package:qpgraph             R Documentation

_C_l_i_q_u_e _l_i_s_t

_D_e_s_c_r_i_p_t_i_o_n:

     Finds the set of (maximal) cliques of a given undirected graph.

_U_s_a_g_e:

     qpGetCliques(g, clqspervtx=FALSE, verbose=TRUE)

_A_r_g_u_m_e_n_t_s:

       g: either a 'graphNEL' object or an incidence matrix of the
          given undirected graph.

clqspervtx: logical; if TRUE then the resulting list returned by the
          function includes additionally p entries at the beginning
          (p=number of variables) each corresponding to a vertex in the
          graph and containing the indices of the cliques where that
          vertex belongs to; if FALSE these additional entries are not
          included (default).

 verbose: show progress on calculations.

_D_e_t_a_i_l_s:

     To find the list of all (maximal) cliques in an undirected graph
     is an NP-complete problem which means that its computational cost
     is bounded by an exponential running time (Karp, 1972). For this
     reason, this is an extremely time and memory consuming computation
     for large dense graphs. The current implementation uses C code
     from the GNU GPL Cliquer library by Niskanen and Ostergard (2003).

_V_a_l_u_e:

     A list of maximal cliques. When 'clqspervtx=TRUE' the first p
     entries (p=number of variables) contain, each of them, the indices
     of the cliques where that particular vertex belongs to.

_A_u_t_h_o_r(_s):

     R. Castelo

_R_e_f_e_r_e_n_c_e_s:

     Castelo, R. and Roverato, A. A robust procedure for Gaussian
     graphical model search from microarray data with p larger than n.
     _J. Mach. Learn. Res._, 7:2621-2650, 2006.

     Niskanen, S. Ostergard, P. Cliquer User's Guide, Version 1.0.
     Communications Laboratory, Helsinki University of Technology,
     Espoo, Finland, Tech. Rep. T48, 2003. (<URL:
     http://users.tkk.fi/~pat/cliquer.html>)

     Karp, R.M. Reducibility among combinatorial problems. In R.E.
     Miller and J.W. Thatcher (eds.): _Complexity of Computer
     Computations_, 85-103, New York: Plenum, 1972.

_S_e_e _A_l_s_o:

     'qpCliqueNumber' 'qpIPF'

_E_x_a_m_p_l_e_s:

     nVertices <- 50 # number of vertices
     maxCon <- 5  # maximum connectivity per vertex

     I <- qpRndGraph(n.vtx=nVertices, n.bd=maxCon)

     clqs <- qpGetCliques(I, verbose=FALSE)

     summary(unlist(lapply(clqs, length)))

     maxCon <- 10  # maximum connectivity per vertex

     I <- qpRndGraph(n.vtx=nVertices, n.bd=maxCon)

     clqs <- qpGetCliques(I, verbose=FALSE)

     summary(unlist(lapply(clqs, length)))

