diff --git a/R/RcppExports.R b/R/RcppExports.R
index 09882cf..b68a3d6 100644
--- a/R/RcppExports.R
+++ b/R/RcppExports.R
@@ -1,26 +1,6 @@
 # Generated by using Rcpp::compileAttributes() -> do not edit by hand
 # Generator token: 10BE3573-1514-4C36-9D1C-5A225CD40393
 
-r_bigclam_init <- function(X, n_comm) {
-    .Call('_scdemon_r_bigclam_init', PACKAGE = 'scdemon', X, n_comm)
-}
-
-r_bigclam <- function(C, n_comm, max_iter = 1000L) {
-    .Call('_scdemon_r_bigclam', PACKAGE = 'scdemon', C, n_comm, max_iter)
-}
-
-r_graph_conductance <- function(X, min_deg) {
-    .Call('_scdemon_r_graph_conductance', PACKAGE = 'scdemon', X, min_deg)
-}
-
-r_graph_conductance_row <- function(X, i, degree, deg_sum, min_deg) {
-    .Call('_scdemon_r_graph_conductance_row', PACKAGE = 'scdemon', X, i, degree, deg_sum, min_deg)
-}
-
-r_graph_degree <- function(X, diag = FALSE) {
-    .Call('_scdemon_r_graph_degree', PACKAGE = 'scdemon', X, diag)
-}
-
 r_ols_beta <- function(X, Y) {
     .Call('_scdemon_r_ols_beta', PACKAGE = 'scdemon', X, Y)
 }
diff --git a/src/RcppExports.cpp b/src/RcppExports.cpp
index 7459c89..1fa66e7 100644
--- a/src/RcppExports.cpp
+++ b/src/RcppExports.cpp
@@ -11,70 +11,6 @@ Rcpp::Rostream<true>&  Rcpp::Rcout = Rcpp::Rcpp_cout_get();
 Rcpp::Rostream<false>& Rcpp::Rcerr = Rcpp::Rcpp_cerr_get();
 #endif
 
-// r_bigclam_init
-Eigen::MatrixXd r_bigclam_init(const Eigen::Map<Eigen::SparseMatrix<double> >& X, int n_comm);
-RcppExport SEXP _scdemon_r_bigclam_init(SEXP XSEXP, SEXP n_commSEXP) {
-BEGIN_RCPP
-    Rcpp::RObject rcpp_result_gen;
-    Rcpp::RNGScope rcpp_rngScope_gen;
-    Rcpp::traits::input_parameter< const Eigen::Map<Eigen::SparseMatrix<double> >& >::type X(XSEXP);
-    Rcpp::traits::input_parameter< int >::type n_comm(n_commSEXP);
-    rcpp_result_gen = Rcpp::wrap(r_bigclam_init(X, n_comm));
-    return rcpp_result_gen;
-END_RCPP
-}
-// r_bigclam
-Eigen::ArrayXXd r_bigclam(const Eigen::Map<Eigen::SparseMatrix<double> >& C, int n_comm, int max_iter);
-RcppExport SEXP _scdemon_r_bigclam(SEXP CSEXP, SEXP n_commSEXP, SEXP max_iterSEXP) {
-BEGIN_RCPP
-    Rcpp::RObject rcpp_result_gen;
-    Rcpp::RNGScope rcpp_rngScope_gen;
-    Rcpp::traits::input_parameter< const Eigen::Map<Eigen::SparseMatrix<double> >& >::type C(CSEXP);
-    Rcpp::traits::input_parameter< int >::type n_comm(n_commSEXP);
-    Rcpp::traits::input_parameter< int >::type max_iter(max_iterSEXP);
-    rcpp_result_gen = Rcpp::wrap(r_bigclam(C, n_comm, max_iter));
-    return rcpp_result_gen;
-END_RCPP
-}
-// r_graph_conductance
-Eigen::ArrayXd r_graph_conductance(const Eigen::Map<Eigen::SparseMatrix<double> >& X, int min_deg);
-RcppExport SEXP _scdemon_r_graph_conductance(SEXP XSEXP, SEXP min_degSEXP) {
-BEGIN_RCPP
-    Rcpp::RObject rcpp_result_gen;
-    Rcpp::RNGScope rcpp_rngScope_gen;
-    Rcpp::traits::input_parameter< const Eigen::Map<Eigen::SparseMatrix<double> >& >::type X(XSEXP);
-    Rcpp::traits::input_parameter< int >::type min_deg(min_degSEXP);
-    rcpp_result_gen = Rcpp::wrap(r_graph_conductance(X, min_deg));
-    return rcpp_result_gen;
-END_RCPP
-}
-// r_graph_conductance_row
-double r_graph_conductance_row(const Eigen::Map<Eigen::SparseMatrix<double> >& X, Eigen::Index i, const Eigen::ArrayXd& degree, double deg_sum, int min_deg);
-RcppExport SEXP _scdemon_r_graph_conductance_row(SEXP XSEXP, SEXP iSEXP, SEXP degreeSEXP, SEXP deg_sumSEXP, SEXP min_degSEXP) {
-BEGIN_RCPP
-    Rcpp::RObject rcpp_result_gen;
-    Rcpp::RNGScope rcpp_rngScope_gen;
-    Rcpp::traits::input_parameter< const Eigen::Map<Eigen::SparseMatrix<double> >& >::type X(XSEXP);
-    Rcpp::traits::input_parameter< Eigen::Index >::type i(iSEXP);
-    Rcpp::traits::input_parameter< const Eigen::ArrayXd& >::type degree(degreeSEXP);
-    Rcpp::traits::input_parameter< double >::type deg_sum(deg_sumSEXP);
-    Rcpp::traits::input_parameter< int >::type min_deg(min_degSEXP);
-    rcpp_result_gen = Rcpp::wrap(r_graph_conductance_row(X, i, degree, deg_sum, min_deg));
-    return rcpp_result_gen;
-END_RCPP
-}
-// r_graph_degree
-Eigen::ArrayXd r_graph_degree(const Eigen::Map<Eigen::SparseMatrix<double> >& X, bool diag);
-RcppExport SEXP _scdemon_r_graph_degree(SEXP XSEXP, SEXP diagSEXP) {
-BEGIN_RCPP
-    Rcpp::RObject rcpp_result_gen;
-    Rcpp::RNGScope rcpp_rngScope_gen;
-    Rcpp::traits::input_parameter< const Eigen::Map<Eigen::SparseMatrix<double> >& >::type X(XSEXP);
-    Rcpp::traits::input_parameter< bool >::type diag(diagSEXP);
-    rcpp_result_gen = Rcpp::wrap(r_graph_degree(X, diag));
-    return rcpp_result_gen;
-END_RCPP
-}
 // r_ols_beta
 Eigen::MatrixXd r_ols_beta(const Eigen::Map<Eigen::MatrixXd>& X, const Eigen::Map<Eigen::MatrixXd>& Y);
 RcppExport SEXP _scdemon_r_ols_beta(SEXP XSEXP, SEXP YSEXP) {
@@ -128,11 +64,6 @@ END_RCPP
 }
 
 static const R_CallMethodDef CallEntries[] = {
-    {"_scdemon_r_bigclam_init", (DL_FUNC) &_scdemon_r_bigclam_init, 2},
-    {"_scdemon_r_bigclam", (DL_FUNC) &_scdemon_r_bigclam, 3},
-    {"_scdemon_r_graph_conductance", (DL_FUNC) &_scdemon_r_graph_conductance, 2},
-    {"_scdemon_r_graph_conductance_row", (DL_FUNC) &_scdemon_r_graph_conductance_row, 5},
-    {"_scdemon_r_graph_degree", (DL_FUNC) &_scdemon_r_graph_degree, 2},
     {"_scdemon_r_ols_beta", (DL_FUNC) &_scdemon_r_ols_beta, 2},
     {"_scdemon_r_ols_resid", (DL_FUNC) &_scdemon_r_ols_resid, 3},
     {"_scdemon_r_robust_se_X", (DL_FUNC) &_scdemon_r_robust_se_X, 2},
diff --git a/src/bigclam.hpp b/src/bigclam.hpp
deleted file mode 100644
index 209d6c1..0000000
--- a/src/bigclam.hpp
+++ /dev/null
@@ -1,59 +0,0 @@
-#ifndef BIGCLAM_HPP
-#define BIGCLAM_HPP
-#include <Eigen/Core>
-#include <Eigen/Dense>
-#include <Eigen/SparseCore>
-#include <algorithm>
-#include <vector>
-
-#include "graph.hpp"
-template<typename T>
-Eigen::MatrixXd bigclam_init(const Eigen::SparseMatrixBase<T> &C, int n_comm)
-{
-        Eigen::ArrayXXd F = Eigen::ArrayXXd::Random(std::min(C.rows(), C.cols()),
-						    n_comm);
-	return ((F + 1.) * 0.5).matrix();
-}
-
-template<typename TV, typename TN, typename TF>
-Eigen::ArrayXd bigclam_gradient(const Eigen::MatrixBase<TV> &node,
-				const Eigen::MatrixBase<TN> &neighbors,
-				const Eigen::ArrayBase<TF> &Fsum0)
-{
-  Eigen::ArrayXd raw = (node * neighbors.transpose()).array().min(15).max(-15).eval();
-  Eigen::ArrayXd scores = (-raw).exp() / (1 - (-raw).exp());
-  Eigen::ArrayXd neighbor_grad = (scores.matrix() * neighbors).array().eval();
-  Eigen::ArrayXd no_neigh_grad = (Fsum0 - node.array() - neighbors.array().colwise().sum()).eval();
-  return neighbor_grad - no_neigh_grad;
-}
-
-// bg edge: \epsilon = 2|E|/(|V||V-1|)
-// todo find out why F increases with # of iterations
-#include <iostream>
-template<typename T>
-Eigen::ArrayXXd bigclam(const Eigen::SparseCompressedBase<T> &C,
-			int n_comm, int max_iter=1000,
-			double conv_threshold=1e-3, double eta=0.005,
-			double min_value=0.00001, double max_value=20)
-{
-        Eigen::MatrixXd F = bigclam_init(C, n_comm);
-	Eigen::ArrayXd Fsum0 = F.colwise().sum();
-	std::cout << "Fsum0 size: " <<  Fsum0.size() << " data: " << Fsum0 << std::endl;
-	for (int iter = 0; iter < max_iter; iter++) {
-	  std::cout << "Iter: " << iter << std::endl;
-	  for (Eigen::Index i = 0; i < C.cols(); i++) {
-	    std::vector<Eigen::Index> neb_idx = graph_neighbors(C, i);
-	    //std::cout << i << " Neighbor: " << neb_idx.size() << std::endl;
-	    if (neb_idx.size() > 0) {
-	      Eigen::MatrixXd F_neighbors = matrix_slice_rows(F, neb_idx);
-	      Eigen::ArrayXd F_node = F.row(i);
-	      Eigen::ArrayXd gradient = bigclam_gradient(F_node.matrix(), F_neighbors, Fsum0);
-	      F.row(i) = F.row(i).array() + eta * gradient;
-	      F.row(i) = F.row(i).array().max(min_value).min(max_value);
-	      Fsum0 = Fsum0 - F_node + F.row(i).array();
-	    }
-	  }
-	}
-	return F.array();
-}
-#endif
diff --git a/src/graph.hpp b/src/graph.hpp
deleted file mode 100644
index 116ec08..0000000
--- a/src/graph.hpp
+++ /dev/null
@@ -1,123 +0,0 @@
-#ifndef GRAPH_HPP
-#define GRAPH_HPP
-
-#include <Eigen/Core>
-#include <Eigen/Dense>
-#include <Eigen/SparseCore>
-#include <vector>
-#include <unordered_set>
-#include <utility>
-#include <algorithm>
-
-#include "implprogress.hpp"
-template<typename T>
-std::vector<std::pair<Eigen::Index, double> > graph_neighbors(const Eigen::SparseCompressedBase<T> &mat,
-							      Eigen::Index outerIndex,
-							      bool weighted=true)
-{
-        std::vector<std::pair<Eigen::Index, double> > out;
-	for (typename T::InnerIterator it(mat, outerIndex); it; ++it) {
-		out.emplace_back(T::IsRowMajor ? it.col() : it.row(),
-				 weighted ? 1. / it.value() : 1.);
-	}
-	return out;
-}
-
-/* Since Eigen 3.4 is not supported in Rcpp, write own iterator */
-template<typename T>
-Eigen::MatrixXd matrix_slice_rows(const Eigen::DenseBase<T> &mat,
-				  const std::vector<std::pair<Eigen::Index, double> > &indices)
-{
-        Eigen::MatrixXd out(indices.size(), mat.cols());
-	for (std::pair<Eigen::Index, double> i : indices) {
-	  	Eigen::ArrayXd row = mat.row(i.first).array() * i.second;
-	        out << row.matrix();
-	}
-	return out;
-}
-
-template<typename T>
-double graph_conductance_row(const Eigen::SparseCompressedBase<T> &mat, Eigen::Index i, const Eigen::ArrayXd& degree, double deg_sum, int min_deg=5)
-{
-	std::unordered_set<Eigen::Index> subgraph = {i};
-	for (typename T::InnerIterator it(mat, i); it; ++it) {
-		Eigen::Index j = T::IsRowMajor ? it.col() : it.row();
-		if (i != j) { 
-			subgraph.insert(j);
-		}
-	}
-	if (subgraph.size() < min_deg) {
-		return 1.;
-	}
-	double subgraph_sum = 0;
-	double subgraph_degree_sum = 0;
-	for (Eigen::Index j : subgraph) {
-		// For each neighbor, add the degrees
-		subgraph_degree_sum += degree(j);
-		for (typename T::InnerIterator it(mat, j); it; ++it) {
-			Eigen::Index k = T::IsRowMajor ? it.col() : it.row();
-			if (j == k) {
-				continue;
-			} else if (subgraph.find(k) != subgraph.end()) {
-				subgraph_sum += it.value();
-			}
-		}
-	}
-	/*
-	 * Numerator is the edge crossings:
-	 * Denom is deg sum and its complement
-	 */
-	double numer = subgraph_degree_sum - subgraph_sum;
-	double denom = std::min(subgraph_degree_sum, deg_sum - subgraph_degree_sum);
-	return numer / denom;
-}
-
-template<typename T>
-Eigen::ArrayXd graph_degree(const Eigen::SparseCompressedBase<T> &mat, bool diag=false)
-{
-	Eigen::Index size;
-	if (T::IsRowMajor) {
-		size = mat.rows();
-	} else {
-		size = mat.cols();
-	}
-	Eigen::ArrayXd degree = Eigen::ArrayXd::Zero(size);
-#if defined(_OPENMP)
-#pragma omp parallel for
-#endif
-	for (Eigen::Index i = 0; i < size; i++) {
-		double cur = 0;
-		for (typename T::InnerIterator it(mat, i); it; ++it) {
-			Eigen::Index j = T::IsRowMajor ? it.col() : it.row();
-			if (diag || (i != j)) {
-				cur += it.value();
-			}
-			degree(i) = cur;
-		}
-	}
-	return degree;
-}
-template<typename T>
-Eigen::ArrayXd graph_conductance(const Eigen::SparseCompressedBase<T> &mat, int min_deg=5)
-{
-	Eigen::ArrayXd degree = graph_degree(mat, false);
-	const double deg_sum = degree.sum();
-	ImplProgress p(mat.cols());
-	Eigen::ArrayXd conductance = Eigen::ArrayXd::Ones(degree.size());
-#if defined(_OPENMP)
-#pragma omp parallel for
-#endif
-	for (Eigen::Index i = 0; i < mat.cols(); i++) {
-	/*
-	 * For each index, find the subgraph defined
-	 * by the immediate neighbors of row i
-	 */
-		if (!p.check_abort()) {
-			p.increment();
-			double cond = graph_conductance_row(mat, i, degree, deg_sum, min_deg);
-			conductance(i) = cond;
-		}
-	}
-	return conductance;
-}
-#endif
diff --git a/src/r_bigclam.cpp b/src/r_bigclam.cpp
deleted file mode 100644
index 0b4b004..0000000
--- a/src/r_bigclam.cpp
+++ /dev/null
@@ -1,23 +0,0 @@
-
-#include <Rcpp.h>
-// [[Rcpp::plugins(openmp)]]
-
-#include <RcppEigen.h>
-// [[Rcpp::depends(RcppEigen)]]
-
-#include "bigclam.hpp"
-
-// [[Rcpp::export]]
-Eigen::MatrixXd r_bigclam_init(const Eigen::Map<Eigen::SparseMatrix<double> > &X,
-			  int n_comm)
-{
-  return bigclam_init(X, n_comm);
-}
-
-
-// [[Rcpp::export]]
-Eigen::ArrayXXd r_bigclam(const Eigen::Map<Eigen::SparseMatrix<double> >&C,
-			 int n_comm, int max_iter=1000)
-{
-  return bigclam(C, n_comm, max_iter);
-}
diff --git a/src/r_graph.cpp b/src/r_graph.cpp
deleted file mode 100644
index a9ea497..0000000
--- a/src/r_graph.cpp
+++ /dev/null
@@ -1,31 +0,0 @@
-
-#include <Rcpp.h>
-// [[Rcpp::plugins(openmp)]]
-
-#include <RcppEigen.h>
-// [[Rcpp::depends(RcppEigen)]]
-
-#include "graph.hpp"
-
-// [[Rcpp::export]]
-Eigen::ArrayXd r_graph_conductance(const Eigen::Map<Eigen::SparseMatrix<double> > &X,
-				   int min_deg)
-{
-	return graph_conductance(X, min_deg);
-}
-
-// [[Rcpp::export]]
-double r_graph_conductance_row(const Eigen::Map<Eigen::SparseMatrix<double> > &X,
-				       Eigen::Index i,
-				       const Eigen::ArrayXd& degree,
-				       double deg_sum,
-				       int min_deg)
-{
-	return graph_conductance_row(X, i, degree, deg_sum, min_deg);
-}
-// [[Rcpp::export]]
-Eigen::ArrayXd r_graph_degree(const Eigen::Map<Eigen::SparseMatrix<double> > &X,
-			      bool diag=false)
-{
-  return graph_degree(X, diag);
-}