diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/ldr.cpp | 39 | ||||
-rw-r--r-- | src/ldr.h | 6 | ||||
-rw-r--r-- | src/param.cpp | 2 |
3 files changed, 4 insertions, 43 deletions
diff --git a/src/ldr.cpp b/src/ldr.cpp index f70eb85..a4ef40a 100644 --- a/src/ldr.cpp +++ b/src/ldr.cpp @@ -29,7 +29,6 @@ #include <stdio.h> #include <stdlib.h> -// #include "Eigen/Dense" #include "gsl/gsl_blas.h" #include "gsl/gsl_cdf.h" #include "gsl/gsl_eigen.h" @@ -46,7 +45,6 @@ #include "param.h" using namespace std; -// using namespace Eigen; void LDR::CopyFromParam(PARAM &cPar) { a_mode = cPar.a_mode; @@ -73,40 +71,3 @@ void LDR::CopyFromParam(PARAM &cPar) { void LDR::CopyToParam(PARAM &cPar) { return; } -/* -// X is a p by n matrix. -void LDR::VB(const vector<vector<unsigned char>> &Xt, const gsl_matrix *W_gsl, - const gsl_vector *y_gsl) { - - // Save gsl_vector and gsl_matrix into Eigen library formats. - MatrixXd W(W_gsl->size1, W_gsl->size2); - VectorXd y(y_gsl->size); - VectorXd x_col(y_gsl->size); - - double d; - for (size_t i = 0; i < W_gsl->size1; i++) { - d = gsl_vector_get(y_gsl, i); - y(i) = d; - for (size_t j = 0; j < W_gsl->size2; j++) { - W(i, j) = gsl_matrix_get(W_gsl, i, j); - } - } - - // Initial VB values by lm. - cout << indicator_snp[0] << " " << indicator_snp[1] << " " << indicator_snp[2] - << endl; - uchar_matrix_get_row(Xt, 0, x_col); - - for (size_t j = 0; j < 10; j++) { - cout << x_col(j) << endl; - } - - // Run VB iterations. - // TO DO. - - // Save results. - // TO DO. - - return; -} -*/ @@ -20,8 +20,8 @@ #define __LDR_H__ #include "param.h" -#include <gsl/gsl_randist.h> -#include <gsl/gsl_rng.h> +// #include <gsl/gsl_randist.h> +// #include <gsl/gsl_rng.h> #include <map> #include <vector> @@ -56,7 +56,7 @@ public: vector<SNPINFO> snpInfo; // Record SNP information. // Not included in PARAM. - gsl_rng *gsl_r; + // gsl_rng *gsl_r; // Main functions. void CopyFromParam(PARAM &cPar); diff --git a/src/param.cpp b/src/param.cpp index cc4290c..e4781c4 100644 --- a/src/param.cpp +++ b/src/param.cpp @@ -1961,7 +1961,7 @@ void PARAM::CheckCvt() { return; } -// Post-process phentoypes and covariates. +// Post-process phenotypes and covariates. void PARAM::ProcessCvtPhen() { // Convert indicator_pheno to indicator_idv. |