SCORE+

This archive contains a R implementation of SCORE+ algorithm as described in the paper 
J. Jin, Z. Ke and S. Luo (2018) SCORE+ for Network Community Detection

Current version 

V1.0

** Function: SCOREplus **

Usage:	
	 [label] = SCOREplus(A, k, c, r);


Inputs: 
	A: n by n adjacency matrix where n is the number of nodes. It should be symmetric and connected
	k: Number of communities, which should be > 1.

Inputs (Optional):
	c: Tuning parameter for constructing Graph Laplacian. Default is 0.1.
        r: Number of eigenvectors to use (>1), if not given, chosen between k and k+1 determined by eigen-gap.

Output: 
	label: n by 1 vector, as is the predicted community labels.

-----------------------------------------------
Example 1: 

# Use default parameter, i.e. set tuning parameter c = 0.1 and use eigen-gap to select the number of eigenvectors to use.

load('simmons.RData')
simmons.out = SCOREplus(A = simmons$adj, k = 4)
getError(simmons.out$labels, simmons$labels)

Example 2:
 
# Set tuning parameter c = 0.05 and use eigen-gap to select the number of eigenvectors to use.

load('simmons.RData')
simmons.out = SCOREplus(A = simmons$adj, k = 4, c = 0.05)
getError(simmons.out$labels, simmons$labels)

Example 3:
 
# Set tuning parameter c = 0.05 and set the number of eigenvectors to use as r = 4.

load('simmons.RData')
simmons.out = SCOREplus(A = simmons$adj, k = 4, c = 0.05, r = 4)
getError(simmons.out$labels, simmons$labels)

-----------------------------------------------
	 
 
LICENSE

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program.  If not, see <http://www.gnu.org/licenses/>.

If you use this code for your publication, please include a reference to the paper: "SCORE+ for Network Community Detection".
 
 
CONTACT
For any problem, please contact
Jiashun Jin 
Department of Statistics 
Carnegie Mellon University 
Email: jiashun@stat.cmu.edu
Zheng tracy Ke 
Department of Statistics 
Harvard University
Email: zke@fas.harvard.edu
Shengming Luo
Department of Statistics 
Carnegie Mellon University 
Email: shengmil@andrew.cmu.edu