// Generated by using Rcpp::compileAttributes() -> do not edit by hand
// Generator token: 10BE3573-1514-4C36-9D1C-5A225CD40393

#include <Rcpp.h>

using namespace Rcpp;

#ifdef RCPP_USE_GLOBAL_ROSTREAM
Rcpp::Rostream<true>&  Rcpp::Rcout = Rcpp::Rcpp_cout_get();
Rcpp::Rostream<false>& Rcpp::Rcerr = Rcpp::Rcpp_cerr_get();
#endif

// EMAlgorithmFull
Rcpp::List EMAlgorithmFull(Rcpp::NumericMatrix candidate_matrix, Rcpp::NumericMatrix group_matrix, Rcpp::String em_method, Rcpp::String probability_method, Rcpp::IntegerVector maximum_iterations, Rcpp::NumericVector maximum_seconds, Rcpp::NumericVector stopping_threshold, Rcpp::NumericVector log_stopping_threshold, Rcpp::LogicalVector compute_ll, Rcpp::LogicalVector verbose, Rcpp::IntegerVector step_size, Rcpp::IntegerVector samples, Rcpp::String monte_method, Rcpp::NumericVector monte_error, Rcpp::IntegerVector monte_iter, Rcpp::IntegerVector miniterations, Rcpp::String LP_method, Rcpp::LogicalVector project_every, Rcpp::NumericMatrix initial_probabilities, Rcpp::LogicalVector symmetric, Rcpp::String symmetric_weight_method);
RcppExport SEXP _fastei_EMAlgorithmFull(SEXP candidate_matrixSEXP, SEXP group_matrixSEXP, SEXP em_methodSEXP, SEXP probability_methodSEXP, SEXP maximum_iterationsSEXP, SEXP maximum_secondsSEXP, SEXP stopping_thresholdSEXP, SEXP log_stopping_thresholdSEXP, SEXP compute_llSEXP, SEXP verboseSEXP, SEXP step_sizeSEXP, SEXP samplesSEXP, SEXP monte_methodSEXP, SEXP monte_errorSEXP, SEXP monte_iterSEXP, SEXP miniterationsSEXP, SEXP LP_methodSEXP, SEXP project_everySEXP, SEXP initial_probabilitiesSEXP, SEXP symmetricSEXP, SEXP symmetric_weight_methodSEXP) {
BEGIN_RCPP
    Rcpp::RObject rcpp_result_gen;
    Rcpp::RNGScope rcpp_rngScope_gen;
    Rcpp::traits::input_parameter< Rcpp::NumericMatrix >::type candidate_matrix(candidate_matrixSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericMatrix >::type group_matrix(group_matrixSEXP);
    Rcpp::traits::input_parameter< Rcpp::String >::type em_method(em_methodSEXP);
    Rcpp::traits::input_parameter< Rcpp::String >::type probability_method(probability_methodSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type maximum_iterations(maximum_iterationsSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericVector >::type maximum_seconds(maximum_secondsSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericVector >::type stopping_threshold(stopping_thresholdSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericVector >::type log_stopping_threshold(log_stopping_thresholdSEXP);
    Rcpp::traits::input_parameter< Rcpp::LogicalVector >::type compute_ll(compute_llSEXP);
    Rcpp::traits::input_parameter< Rcpp::LogicalVector >::type verbose(verboseSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type step_size(step_sizeSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type samples(samplesSEXP);
    Rcpp::traits::input_parameter< Rcpp::String >::type monte_method(monte_methodSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericVector >::type monte_error(monte_errorSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type monte_iter(monte_iterSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type miniterations(miniterationsSEXP);
    Rcpp::traits::input_parameter< Rcpp::String >::type LP_method(LP_methodSEXP);
    Rcpp::traits::input_parameter< Rcpp::LogicalVector >::type project_every(project_everySEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericMatrix >::type initial_probabilities(initial_probabilitiesSEXP);
    Rcpp::traits::input_parameter< Rcpp::LogicalVector >::type symmetric(symmetricSEXP);
    Rcpp::traits::input_parameter< Rcpp::String >::type symmetric_weight_method(symmetric_weight_methodSEXP);
    rcpp_result_gen = Rcpp::wrap(EMAlgorithmFull(candidate_matrix, group_matrix, em_method, probability_method, maximum_iterations, maximum_seconds, stopping_threshold, log_stopping_threshold, compute_ll, verbose, step_size, samples, monte_method, monte_error, monte_iter, miniterations, LP_method, project_every, initial_probabilities, symmetric, symmetric_weight_method));
    return rcpp_result_gen;
END_RCPP
}
// EMLogLikFromProb
double EMLogLikFromProb(Rcpp::NumericMatrix candidate_matrix, Rcpp::NumericMatrix group_matrix, Rcpp::NumericMatrix probability_matrix, Rcpp::String em_method, Rcpp::IntegerVector step_size, Rcpp::IntegerVector samples, Rcpp::String monte_method, Rcpp::NumericVector monte_error, Rcpp::IntegerVector monte_iter, Rcpp::IntegerVector miniterations, Rcpp::String LP_method, Rcpp::LogicalVector project_every);
RcppExport SEXP _fastei_EMLogLikFromProb(SEXP candidate_matrixSEXP, SEXP group_matrixSEXP, SEXP probability_matrixSEXP, SEXP em_methodSEXP, SEXP step_sizeSEXP, SEXP samplesSEXP, SEXP monte_methodSEXP, SEXP monte_errorSEXP, SEXP monte_iterSEXP, SEXP miniterationsSEXP, SEXP LP_methodSEXP, SEXP project_everySEXP) {
BEGIN_RCPP
    Rcpp::RObject rcpp_result_gen;
    Rcpp::RNGScope rcpp_rngScope_gen;
    Rcpp::traits::input_parameter< Rcpp::NumericMatrix >::type candidate_matrix(candidate_matrixSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericMatrix >::type group_matrix(group_matrixSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericMatrix >::type probability_matrix(probability_matrixSEXP);
    Rcpp::traits::input_parameter< Rcpp::String >::type em_method(em_methodSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type step_size(step_sizeSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type samples(samplesSEXP);
    Rcpp::traits::input_parameter< Rcpp::String >::type monte_method(monte_methodSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericVector >::type monte_error(monte_errorSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type monte_iter(monte_iterSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type miniterations(miniterationsSEXP);
    Rcpp::traits::input_parameter< Rcpp::String >::type LP_method(LP_methodSEXP);
    Rcpp::traits::input_parameter< Rcpp::LogicalVector >::type project_every(project_everySEXP);
    rcpp_result_gen = Rcpp::wrap(EMLogLikFromProb(candidate_matrix, group_matrix, probability_matrix, em_method, step_size, samples, monte_method, monte_error, monte_iter, miniterations, LP_method, project_every));
    return rcpp_result_gen;
END_RCPP
}
// bootstrapAlg
Rcpp::List bootstrapAlg(Rcpp::NumericMatrix candidate_matrix, Rcpp::NumericMatrix group_matrix, Rcpp::IntegerVector nboot, Rcpp::String em_method, Rcpp::String probability_method, Rcpp::IntegerVector maximum_iterations, Rcpp::NumericVector maximum_seconds, Rcpp::NumericVector stopping_threshold, Rcpp::NumericVector log_stopping_threshold, Rcpp::LogicalVector compute_ll, Rcpp::LogicalVector verbose, Rcpp::IntegerVector step_size, Rcpp::IntegerVector samples, Rcpp::String monte_method, Rcpp::NumericVector monte_error, Rcpp::IntegerVector monte_iter, Rcpp::IntegerVector miniterations, Rcpp::String LP_method, Rcpp::LogicalVector project_every, Rcpp::NumericMatrix initial_probabilities);
RcppExport SEXP _fastei_bootstrapAlg(SEXP candidate_matrixSEXP, SEXP group_matrixSEXP, SEXP nbootSEXP, SEXP em_methodSEXP, SEXP probability_methodSEXP, SEXP maximum_iterationsSEXP, SEXP maximum_secondsSEXP, SEXP stopping_thresholdSEXP, SEXP log_stopping_thresholdSEXP, SEXP compute_llSEXP, SEXP verboseSEXP, SEXP step_sizeSEXP, SEXP samplesSEXP, SEXP monte_methodSEXP, SEXP monte_errorSEXP, SEXP monte_iterSEXP, SEXP miniterationsSEXP, SEXP LP_methodSEXP, SEXP project_everySEXP, SEXP initial_probabilitiesSEXP) {
BEGIN_RCPP
    Rcpp::RObject rcpp_result_gen;
    Rcpp::RNGScope rcpp_rngScope_gen;
    Rcpp::traits::input_parameter< Rcpp::NumericMatrix >::type candidate_matrix(candidate_matrixSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericMatrix >::type group_matrix(group_matrixSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type nboot(nbootSEXP);
    Rcpp::traits::input_parameter< Rcpp::String >::type em_method(em_methodSEXP);
    Rcpp::traits::input_parameter< Rcpp::String >::type probability_method(probability_methodSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type maximum_iterations(maximum_iterationsSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericVector >::type maximum_seconds(maximum_secondsSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericVector >::type stopping_threshold(stopping_thresholdSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericVector >::type log_stopping_threshold(log_stopping_thresholdSEXP);
    Rcpp::traits::input_parameter< Rcpp::LogicalVector >::type compute_ll(compute_llSEXP);
    Rcpp::traits::input_parameter< Rcpp::LogicalVector >::type verbose(verboseSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type step_size(step_sizeSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type samples(samplesSEXP);
    Rcpp::traits::input_parameter< Rcpp::String >::type monte_method(monte_methodSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericVector >::type monte_error(monte_errorSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type monte_iter(monte_iterSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type miniterations(miniterationsSEXP);
    Rcpp::traits::input_parameter< Rcpp::String >::type LP_method(LP_methodSEXP);
    Rcpp::traits::input_parameter< Rcpp::LogicalVector >::type project_every(project_everySEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericMatrix >::type initial_probabilities(initial_probabilitiesSEXP);
    rcpp_result_gen = Rcpp::wrap(bootstrapAlg(candidate_matrix, group_matrix, nboot, em_method, probability_method, maximum_iterations, maximum_seconds, stopping_threshold, log_stopping_threshold, compute_ll, verbose, step_size, samples, monte_method, monte_error, monte_iter, miniterations, LP_method, project_every, initial_probabilities));
    return rcpp_result_gen;
END_RCPP
}
// groupAgg
Rcpp::List groupAgg(Rcpp::String sd_statistic, Rcpp::NumericVector sd_threshold, Rcpp::LogicalVector feasible, Rcpp::NumericMatrix candidate_matrix, Rcpp::NumericMatrix group_matrix, Rcpp::IntegerVector nboot, Rcpp::String em_method, Rcpp::String probability_method, Rcpp::IntegerVector maximum_iterations, Rcpp::NumericVector maximum_seconds, Rcpp::NumericVector stopping_threshold, Rcpp::NumericVector log_stopping_threshold, Rcpp::LogicalVector compute_ll, Rcpp::LogicalVector verbose, Rcpp::IntegerVector step_size, Rcpp::IntegerVector samples, Rcpp::String monte_method, Rcpp::NumericVector monte_error, Rcpp::IntegerVector monte_iter, Rcpp::IntegerVector miniterations, Rcpp::String LP_method, Rcpp::LogicalVector project_every, Rcpp::NumericMatrix initial_probabilities);
RcppExport SEXP _fastei_groupAgg(SEXP sd_statisticSEXP, SEXP sd_thresholdSEXP, SEXP feasibleSEXP, SEXP candidate_matrixSEXP, SEXP group_matrixSEXP, SEXP nbootSEXP, SEXP em_methodSEXP, SEXP probability_methodSEXP, SEXP maximum_iterationsSEXP, SEXP maximum_secondsSEXP, SEXP stopping_thresholdSEXP, SEXP log_stopping_thresholdSEXP, SEXP compute_llSEXP, SEXP verboseSEXP, SEXP step_sizeSEXP, SEXP samplesSEXP, SEXP monte_methodSEXP, SEXP monte_errorSEXP, SEXP monte_iterSEXP, SEXP miniterationsSEXP, SEXP LP_methodSEXP, SEXP project_everySEXP, SEXP initial_probabilitiesSEXP) {
BEGIN_RCPP
    Rcpp::RObject rcpp_result_gen;
    Rcpp::RNGScope rcpp_rngScope_gen;
    Rcpp::traits::input_parameter< Rcpp::String >::type sd_statistic(sd_statisticSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericVector >::type sd_threshold(sd_thresholdSEXP);
    Rcpp::traits::input_parameter< Rcpp::LogicalVector >::type feasible(feasibleSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericMatrix >::type candidate_matrix(candidate_matrixSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericMatrix >::type group_matrix(group_matrixSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type nboot(nbootSEXP);
    Rcpp::traits::input_parameter< Rcpp::String >::type em_method(em_methodSEXP);
    Rcpp::traits::input_parameter< Rcpp::String >::type probability_method(probability_methodSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type maximum_iterations(maximum_iterationsSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericVector >::type maximum_seconds(maximum_secondsSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericVector >::type stopping_threshold(stopping_thresholdSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericVector >::type log_stopping_threshold(log_stopping_thresholdSEXP);
    Rcpp::traits::input_parameter< Rcpp::LogicalVector >::type compute_ll(compute_llSEXP);
    Rcpp::traits::input_parameter< Rcpp::LogicalVector >::type verbose(verboseSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type step_size(step_sizeSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type samples(samplesSEXP);
    Rcpp::traits::input_parameter< Rcpp::String >::type monte_method(monte_methodSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericVector >::type monte_error(monte_errorSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type monte_iter(monte_iterSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type miniterations(miniterationsSEXP);
    Rcpp::traits::input_parameter< Rcpp::String >::type LP_method(LP_methodSEXP);
    Rcpp::traits::input_parameter< Rcpp::LogicalVector >::type project_every(project_everySEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericMatrix >::type initial_probabilities(initial_probabilitiesSEXP);
    rcpp_result_gen = Rcpp::wrap(groupAgg(sd_statistic, sd_threshold, feasible, candidate_matrix, group_matrix, nboot, em_method, probability_method, maximum_iterations, maximum_seconds, stopping_threshold, log_stopping_threshold, compute_ll, verbose, step_size, samples, monte_method, monte_error, monte_iter, miniterations, LP_method, project_every, initial_probabilities));
    return rcpp_result_gen;
END_RCPP
}
// groupAggGreedy
Rcpp::List groupAggGreedy(Rcpp::String sd_statistic, Rcpp::NumericVector sd_threshold, Rcpp::NumericMatrix candidate_matrix, Rcpp::NumericMatrix group_matrix, Rcpp::IntegerVector nboot, Rcpp::String em_method, Rcpp::String probability_method, Rcpp::IntegerVector maximum_iterations, Rcpp::NumericVector maximum_seconds, Rcpp::NumericVector stopping_threshold, Rcpp::NumericVector log_stopping_threshold, Rcpp::NumericVector compute_ll, Rcpp::LogicalVector verbose, Rcpp::IntegerVector step_size, Rcpp::IntegerVector samples, Rcpp::String monte_method, Rcpp::NumericVector monte_error, Rcpp::IntegerVector monte_iter, Rcpp::IntegerVector miniterations, Rcpp::String LP_method, Rcpp::LogicalVector project_every);
RcppExport SEXP _fastei_groupAggGreedy(SEXP sd_statisticSEXP, SEXP sd_thresholdSEXP, SEXP candidate_matrixSEXP, SEXP group_matrixSEXP, SEXP nbootSEXP, SEXP em_methodSEXP, SEXP probability_methodSEXP, SEXP maximum_iterationsSEXP, SEXP maximum_secondsSEXP, SEXP stopping_thresholdSEXP, SEXP log_stopping_thresholdSEXP, SEXP compute_llSEXP, SEXP verboseSEXP, SEXP step_sizeSEXP, SEXP samplesSEXP, SEXP monte_methodSEXP, SEXP monte_errorSEXP, SEXP monte_iterSEXP, SEXP miniterationsSEXP, SEXP LP_methodSEXP, SEXP project_everySEXP) {
BEGIN_RCPP
    Rcpp::RObject rcpp_result_gen;
    Rcpp::RNGScope rcpp_rngScope_gen;
    Rcpp::traits::input_parameter< Rcpp::String >::type sd_statistic(sd_statisticSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericVector >::type sd_threshold(sd_thresholdSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericMatrix >::type candidate_matrix(candidate_matrixSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericMatrix >::type group_matrix(group_matrixSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type nboot(nbootSEXP);
    Rcpp::traits::input_parameter< Rcpp::String >::type em_method(em_methodSEXP);
    Rcpp::traits::input_parameter< Rcpp::String >::type probability_method(probability_methodSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type maximum_iterations(maximum_iterationsSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericVector >::type maximum_seconds(maximum_secondsSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericVector >::type stopping_threshold(stopping_thresholdSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericVector >::type log_stopping_threshold(log_stopping_thresholdSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericVector >::type compute_ll(compute_llSEXP);
    Rcpp::traits::input_parameter< Rcpp::LogicalVector >::type verbose(verboseSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type step_size(step_sizeSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type samples(samplesSEXP);
    Rcpp::traits::input_parameter< Rcpp::String >::type monte_method(monte_methodSEXP);
    Rcpp::traits::input_parameter< Rcpp::NumericVector >::type monte_error(monte_errorSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type monte_iter(monte_iterSEXP);
    Rcpp::traits::input_parameter< Rcpp::IntegerVector >::type miniterations(miniterationsSEXP);
    Rcpp::traits::input_parameter< Rcpp::String >::type LP_method(LP_methodSEXP);
    Rcpp::traits::input_parameter< Rcpp::LogicalVector >::type project_every(project_everySEXP);
    rcpp_result_gen = Rcpp::wrap(groupAggGreedy(sd_statistic, sd_threshold, candidate_matrix, group_matrix, nboot, em_method, probability_method, maximum_iterations, maximum_seconds, stopping_threshold, log_stopping_threshold, compute_ll, verbose, step_size, samples, monte_method, monte_error, monte_iter, miniterations, LP_method, project_every));
    return rcpp_result_gen;
END_RCPP
}

static const R_CallMethodDef CallEntries[] = {
    {"_fastei_EMAlgorithmFull", (DL_FUNC) &_fastei_EMAlgorithmFull, 21},
    {"_fastei_EMLogLikFromProb", (DL_FUNC) &_fastei_EMLogLikFromProb, 12},
    {"_fastei_bootstrapAlg", (DL_FUNC) &_fastei_bootstrapAlg, 20},
    {"_fastei_groupAgg", (DL_FUNC) &_fastei_groupAgg, 23},
    {"_fastei_groupAggGreedy", (DL_FUNC) &_fastei_groupAggGreedy, 21},
    {NULL, NULL, 0}
};

RcppExport void R_init_fastei(DllInfo *dll) {
    R_registerRoutines(dll, NULL, CallEntries, NULL, NULL);
    R_useDynamicSymbols(dll, FALSE);
}
