| 5687abab |
// Generated by using Rcpp::compileAttributes() -> do not edit by hand
// Generator token: 10BE3573-1514-4C36-9D1C-5A225CD40393
#include <RcppArmadillo.h>
#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
// NBthDE_paraOptfeat
List NBthDE_paraOptfeat(arma::mat& X, arma::vec y, arma::vec alpha0, arma::vec alpha, arma::mat& preci1, double threshold0, double preci2, arma::vec& x0, bool calhes);
RcppExport SEXP _GeoDiff_NBthDE_paraOptfeat(SEXP XSEXP, SEXP ySEXP, SEXP alpha0SEXP, SEXP alphaSEXP, SEXP preci1SEXP, SEXP threshold0SEXP, SEXP preci2SEXP, SEXP x0SEXP, SEXP calhesSEXP) {
BEGIN_RCPP
Rcpp::RObject rcpp_result_gen;
Rcpp::RNGScope rcpp_rngScope_gen;
Rcpp::traits::input_parameter< arma::mat& >::type X(XSEXP);
Rcpp::traits::input_parameter< arma::vec >::type y(ySEXP);
Rcpp::traits::input_parameter< arma::vec >::type alpha0(alpha0SEXP);
Rcpp::traits::input_parameter< arma::vec >::type alpha(alphaSEXP);
Rcpp::traits::input_parameter< arma::mat& >::type preci1(preci1SEXP);
Rcpp::traits::input_parameter< double >::type threshold0(threshold0SEXP);
Rcpp::traits::input_parameter< double >::type preci2(preci2SEXP);
Rcpp::traits::input_parameter< arma::vec& >::type x0(x0SEXP);
Rcpp::traits::input_parameter< bool >::type calhes(calhesSEXP);
rcpp_result_gen = Rcpp::wrap(NBthDE_paraOptfeat(X, y, alpha0, alpha, preci1, threshold0, preci2, x0, calhes));
return rcpp_result_gen;
END_RCPP
}
// NBthDE_paraOptall
List NBthDE_paraOptall(arma::mat& Y, arma::mat& X, arma::vec& alpha0, arma::vec& alpha, arma::mat& preci1, arma::vec& threshold0, double preci2, arma::vec& x0, bool sizescale, bool calhes);
RcppExport SEXP _GeoDiff_NBthDE_paraOptall(SEXP YSEXP, SEXP XSEXP, SEXP alpha0SEXP, SEXP alphaSEXP, SEXP preci1SEXP, SEXP threshold0SEXP, SEXP preci2SEXP, SEXP x0SEXP, SEXP sizescaleSEXP, SEXP calhesSEXP) {
BEGIN_RCPP
Rcpp::RObject rcpp_result_gen;
Rcpp::RNGScope rcpp_rngScope_gen;
Rcpp::traits::input_parameter< arma::mat& >::type Y(YSEXP);
Rcpp::traits::input_parameter< arma::mat& >::type X(XSEXP);
Rcpp::traits::input_parameter< arma::vec& >::type alpha0(alpha0SEXP);
Rcpp::traits::input_parameter< arma::vec& >::type alpha(alphaSEXP);
Rcpp::traits::input_parameter< arma::mat& >::type preci1(preci1SEXP);
Rcpp::traits::input_parameter< arma::vec& >::type threshold0(threshold0SEXP);
Rcpp::traits::input_parameter< double >::type preci2(preci2SEXP);
Rcpp::traits::input_parameter< arma::vec& >::type x0(x0SEXP);
Rcpp::traits::input_parameter< bool >::type sizescale(sizescaleSEXP);
Rcpp::traits::input_parameter< bool >::type calhes(calhesSEXP);
rcpp_result_gen = Rcpp::wrap(NBthDE_paraOptall(Y, X, alpha0, alpha, preci1, threshold0, preci2, x0, sizescale, calhes));
return rcpp_result_gen;
END_RCPP
}
// NBthmDE_grad
arma::vec NBthmDE_grad(arma::vec& y, arma::mat& X, arma::mat& Z, arma::vec& x, arma::vec& u, arma::vec& alpha0, arma::vec& alpha, arma::mat& preci1, double preci2, double threshold0);
RcppExport SEXP _GeoDiff_NBthmDE_grad(SEXP ySEXP, SEXP XSEXP, SEXP ZSEXP, SEXP xSEXP, SEXP uSEXP, SEXP alpha0SEXP, SEXP alphaSEXP, SEXP preci1SEXP, SEXP preci2SEXP, SEXP threshold0SEXP) {
BEGIN_RCPP
Rcpp::RObject rcpp_result_gen;
Rcpp::RNGScope rcpp_rngScope_gen;
Rcpp::traits::input_parameter< arma::vec& >::type y(ySEXP);
Rcpp::traits::input_parameter< arma::mat& >::type X(XSEXP);
Rcpp::traits::input_parameter< arma::mat& >::type Z(ZSEXP);
Rcpp::traits::input_parameter< arma::vec& >::type x(xSEXP);
Rcpp::traits::input_parameter< arma::vec& >::type u(uSEXP);
Rcpp::traits::input_parameter< arma::vec& >::type alpha0(alpha0SEXP);
Rcpp::traits::input_parameter< arma::vec& >::type alpha(alphaSEXP);
Rcpp::traits::input_parameter< arma::mat& >::type preci1(preci1SEXP);
Rcpp::traits::input_parameter< double >::type preci2(preci2SEXP);
Rcpp::traits::input_parameter< double >::type threshold0(threshold0SEXP);
rcpp_result_gen = Rcpp::wrap(NBthmDE_grad(y, X, Z, x, u, alpha0, alpha, preci1, preci2, threshold0));
return rcpp_result_gen;
END_RCPP
}
// NBthmDE_gradM
arma::mat NBthmDE_gradM(arma::vec& y, arma::mat& X, arma::mat& Z, arma::vec& x, arma::mat& u_mat, arma::vec& alpha0, arma::vec& alpha, arma::mat& preci1, double preci2, double threshold0);
RcppExport SEXP _GeoDiff_NBthmDE_gradM(SEXP ySEXP, SEXP XSEXP, SEXP ZSEXP, SEXP xSEXP, SEXP u_matSEXP, SEXP alpha0SEXP, SEXP alphaSEXP, SEXP preci1SEXP, SEXP preci2SEXP, SEXP threshold0SEXP) {
BEGIN_RCPP
Rcpp::RObject rcpp_result_gen;
Rcpp::RNGScope rcpp_rngScope_gen;
Rcpp::traits::input_parameter< arma::vec& >::type y(ySEXP);
Rcpp::traits::input_parameter< arma::mat& >::type X(XSEXP);
Rcpp::traits::input_parameter< arma::mat& >::type Z(ZSEXP);
Rcpp::traits::input_parameter< arma::vec& >::type x(xSEXP);
Rcpp::traits::input_parameter< arma::mat& >::type u_mat(u_matSEXP);
Rcpp::traits::input_parameter< arma::vec& >::type alpha0(alpha0SEXP);
Rcpp::traits::input_parameter< arma::vec& >::type alpha(alphaSEXP);
Rcpp::traits::input_parameter< arma::mat& >::type preci1(preci1SEXP);
Rcpp::traits::input_parameter< double >::type preci2(preci2SEXP);
Rcpp::traits::input_parameter< double >::type threshold0(threshold0SEXP);
rcpp_result_gen = Rcpp::wrap(NBthmDE_gradM(y, X, Z, x, u_mat, alpha0, alpha, preci1, preci2, threshold0));
return rcpp_result_gen;
END_RCPP
}
// condi_u
List condi_u(arma::mat& Tem, int ind, arma::vec& u, int temp_size);
RcppExport SEXP _GeoDiff_condi_u(SEXP TemSEXP, SEXP indSEXP, SEXP uSEXP, SEXP temp_sizeSEXP) {
BEGIN_RCPP
Rcpp::RObject rcpp_result_gen;
Rcpp::RNGScope rcpp_rngScope_gen;
Rcpp::traits::input_parameter< arma::mat& >::type Tem(TemSEXP);
Rcpp::traits::input_parameter< int >::type ind(indSEXP);
Rcpp::traits::input_parameter< arma::vec& >::type u(uSEXP);
Rcpp::traits::input_parameter< int >::type temp_size(temp_sizeSEXP);
rcpp_result_gen = Rcpp::wrap(condi_u(Tem, ind, u, temp_size));
return rcpp_result_gen;
END_RCPP
}
// NBthmDE_mh
arma::mat NBthmDE_mh(arma::mat& Tem, arma::vec& u, arma::mat& X, arma::mat& Z, arma::vec& y, arma::vec& alpha0, arma::vec& alpha, arma::vec& x, int nmh);
RcppExport SEXP _GeoDiff_NBthmDE_mh(SEXP TemSEXP, SEXP uSEXP, SEXP XSEXP, SEXP ZSEXP, SEXP ySEXP, SEXP alpha0SEXP, SEXP alphaSEXP, SEXP xSEXP, SEXP nmhSEXP) {
BEGIN_RCPP
Rcpp::RObject rcpp_result_gen;
Rcpp::RNGScope rcpp_rngScope_gen;
Rcpp::traits::input_parameter< arma::mat& >::type Tem(TemSEXP);
Rcpp::traits::input_parameter< arma::vec& >::type u(uSEXP);
Rcpp::traits::input_parameter< arma::mat& >::type X(XSEXP);
Rcpp::traits::input_parameter< arma::mat& >::type Z(ZSEXP);
Rcpp::traits::input_parameter< arma::vec& >::type y(ySEXP);
Rcpp::traits::input_parameter< arma::vec& >::type alpha0(alpha0SEXP);
Rcpp::traits::input_parameter< arma::vec& >::type alpha(alphaSEXP);
Rcpp::traits::input_parameter< arma::vec& >::type x(xSEXP);
Rcpp::traits::input_parameter< int >::type nmh(nmhSEXP);
rcpp_result_gen = Rcpp::wrap(NBthmDE_mh(Tem, u, X, Z, y, alpha0, alpha, x, nmh));
return rcpp_result_gen;
END_RCPP
}
// NBthmDE_fparaOptfeat
List NBthmDE_fparaOptfeat(arma::mat& X, arma::mat& Z, arma::vec& y, arma::vec& alpha0, arma::vec& alpha, arma::mat& preci1, double threshold0, double preci2, arma::mat& u_mat, arma::vec& x0, bool calhes);
RcppExport SEXP _GeoDiff_NBthmDE_fparaOptfeat(SEXP XSEXP, SEXP ZSEXP, SEXP ySEXP, SEXP alpha0SEXP, SEXP alphaSEXP, SEXP preci1SEXP, SEXP threshold0SEXP, SEXP preci2SEXP, SEXP u_matSEXP, SEXP x0SEXP, SEXP calhesSEXP) {
BEGIN_RCPP
Rcpp::RObject rcpp_result_gen;
Rcpp::RNGScope rcpp_rngScope_gen;
Rcpp::traits::input_parameter< arma::mat& >::type X(XSEXP);
Rcpp::traits::input_parameter< arma::mat& >::type Z(ZSEXP);
Rcpp::traits::input_parameter< arma::vec& >::type y(ySEXP);
Rcpp::traits::input_parameter< arma::vec& >::type alpha0(alpha0SEXP);
Rcpp::traits::input_parameter< arma::vec& >::type alpha(alphaSEXP);
Rcpp::traits::input_parameter< arma::mat& >::type preci1(preci1SEXP);
Rcpp::traits::input_parameter< double >::type threshold0(threshold0SEXP);
Rcpp::traits::input_parameter< double >::type preci2(preci2SEXP);
Rcpp::traits::input_parameter< arma::mat& >::type u_mat(u_matSEXP);
Rcpp::traits::input_parameter< arma::vec& >::type x0(x0SEXP);
Rcpp::traits::input_parameter< bool >::type calhes(calhesSEXP);
rcpp_result_gen = Rcpp::wrap(NBthmDE_fparaOptfeat(X, Z, y, alpha0, alpha, preci1, threshold0, preci2, u_mat, x0, calhes));
return rcpp_result_gen;
END_RCPP
}
// NBthmDE_uOpt
List NBthmDE_uOpt(arma::vec& u0, arma::mat& X, arma::mat& Z, arma::vec& y, arma::vec& alpha0, arma::vec& alpha, arma::vec& x, arma::mat& preciu, bool calhes);
RcppExport SEXP _GeoDiff_NBthmDE_uOpt(SEXP u0SEXP, SEXP XSEXP, SEXP ZSEXP, SEXP ySEXP, SEXP alpha0SEXP, SEXP alphaSEXP, SEXP xSEXP, SEXP preciuSEXP, SEXP calhesSEXP) {
BEGIN_RCPP
Rcpp::RObject rcpp_result_gen;
Rcpp::RNGScope rcpp_rngScope_gen;
Rcpp::traits::input_parameter< arma::vec& >::type u0(u0SEXP);
Rcpp::traits::input_parameter< arma::mat& >::type X(XSEXP);
Rcpp::traits::input_parameter< arma::mat& >::type Z(ZSEXP);
Rcpp::traits::input_parameter< arma::vec& >::type y(ySEXP);
Rcpp::traits::input_parameter< arma::vec& >::type alpha0(alpha0SEXP);
Rcpp::traits::input_parameter< arma::vec& >::type alpha(alphaSEXP);
Rcpp::traits::input_parameter< arma::vec& >::type x(xSEXP);
Rcpp::traits::input_parameter< arma::mat& >::type preciu(preciuSEXP);
Rcpp::traits::input_parameter< bool >::type calhes(calhesSEXP);
rcpp_result_gen = Rcpp::wrap(NBthmDE_uOpt(u0, X, Z, y, alpha0, alpha, x, preciu, calhes));
return rcpp_result_gen;
END_RCPP
}
// PoisthNorm_paraOptfeat
List PoisthNorm_paraOptfeat(arma::vec y, arma::mat& X, arma::vec alpha0, arma::vec alpha, arma::mat& preci1, double preci2, double threshold0, bool calhes);
RcppExport SEXP _GeoDiff_PoisthNorm_paraOptfeat(SEXP ySEXP, SEXP XSEXP, SEXP alpha0SEXP, SEXP alphaSEXP, SEXP preci1SEXP, SEXP preci2SEXP, SEXP threshold0SEXP, SEXP calhesSEXP) {
BEGIN_RCPP
Rcpp::RObject rcpp_result_gen;
Rcpp::RNGScope rcpp_rngScope_gen;
Rcpp::traits::input_parameter< arma::vec >::type y(ySEXP);
Rcpp::traits::input_parameter< arma::mat& >::type X(XSEXP);
Rcpp::traits::input_parameter< arma::vec >::type alpha0(alpha0SEXP);
Rcpp::traits::input_parameter< arma::vec >::type alpha(alphaSEXP);
Rcpp::traits::input_parameter< arma::mat& >::type preci1(preci1SEXP);
Rcpp::traits::input_parameter< double >::type preci2(preci2SEXP);
Rcpp::traits::input_parameter< double >::type threshold0(threshold0SEXP);
Rcpp::traits::input_parameter< bool >::type calhes(calhesSEXP);
rcpp_result_gen = Rcpp::wrap(PoisthNorm_paraOptfeat(y, X, alpha0, alpha, preci1, preci2, threshold0, calhes));
return rcpp_result_gen;
END_RCPP
}
// PoisthNorm_paraOptall
List PoisthNorm_paraOptall(arma::mat& Y, arma::mat& X, arma::vec& alpha0, arma::vec& alpha, arma::mat& preci1, arma::vec& threshold0, double preci2, bool sizescale, bool calhes);
RcppExport SEXP _GeoDiff_PoisthNorm_paraOptall(SEXP YSEXP, SEXP XSEXP, SEXP alpha0SEXP, SEXP alphaSEXP, SEXP preci1SEXP, SEXP threshold0SEXP, SEXP preci2SEXP, SEXP sizescaleSEXP, SEXP calhesSEXP) {
BEGIN_RCPP
Rcpp::RObject rcpp_result_gen;
Rcpp::RNGScope rcpp_rngScope_gen;
Rcpp::traits::input_parameter< arma::mat& >::type Y(YSEXP);
Rcpp::traits::input_parameter< arma::mat& >::type X(XSEXP);
Rcpp::traits::input_parameter< arma::vec& >::type alpha0(alpha0SEXP);
Rcpp::traits::input_parameter< arma::vec& >::type alpha(alphaSEXP);
Rcpp::traits::input_parameter< arma::mat& >::type preci1(preci1SEXP);
Rcpp::traits::input_parameter< arma::vec& >::type threshold0(threshold0SEXP);
Rcpp::traits::input_parameter< double >::type preci2(preci2SEXP);
Rcpp::traits::input_parameter< bool >::type sizescale(sizescaleSEXP);
Rcpp::traits::input_parameter< bool >::type calhes(calhesSEXP);
rcpp_result_gen = Rcpp::wrap(PoisthNorm_paraOptall(Y, X, alpha0, alpha, preci1, threshold0, preci2, sizescale, calhes));
return rcpp_result_gen;
END_RCPP
}
// dnbinom_mu_vec
arma::vec dnbinom_mu_vec(arma::vec x, double sz, arma::vec mu, int lg);
RcppExport SEXP _GeoDiff_dnbinom_mu_vec(SEXP xSEXP, SEXP szSEXP, SEXP muSEXP, SEXP lgSEXP) {
BEGIN_RCPP
Rcpp::RObject rcpp_result_gen;
Rcpp::RNGScope rcpp_rngScope_gen;
Rcpp::traits::input_parameter< arma::vec >::type x(xSEXP);
Rcpp::traits::input_parameter< double >::type sz(szSEXP);
Rcpp::traits::input_parameter< arma::vec >::type mu(muSEXP);
Rcpp::traits::input_parameter< int >::type lg(lgSEXP);
rcpp_result_gen = Rcpp::wrap(dnbinom_mu_vec(x, sz, mu, lg));
return rcpp_result_gen;
END_RCPP
}
static const R_CallMethodDef CallEntries[] = {
{"_GeoDiff_NBthDE_paraOptfeat", (DL_FUNC) &_GeoDiff_NBthDE_paraOptfeat, 9},
{"_GeoDiff_NBthDE_paraOptall", (DL_FUNC) &_GeoDiff_NBthDE_paraOptall, 10},
{"_GeoDiff_NBthmDE_grad", (DL_FUNC) &_GeoDiff_NBthmDE_grad, 10},
{"_GeoDiff_NBthmDE_gradM", (DL_FUNC) &_GeoDiff_NBthmDE_gradM, 10},
{"_GeoDiff_condi_u", (DL_FUNC) &_GeoDiff_condi_u, 4},
{"_GeoDiff_NBthmDE_mh", (DL_FUNC) &_GeoDiff_NBthmDE_mh, 9},
{"_GeoDiff_NBthmDE_fparaOptfeat", (DL_FUNC) &_GeoDiff_NBthmDE_fparaOptfeat, 11},
{"_GeoDiff_NBthmDE_uOpt", (DL_FUNC) &_GeoDiff_NBthmDE_uOpt, 9},
{"_GeoDiff_PoisthNorm_paraOptfeat", (DL_FUNC) &_GeoDiff_PoisthNorm_paraOptfeat, 8},
{"_GeoDiff_PoisthNorm_paraOptall", (DL_FUNC) &_GeoDiff_PoisthNorm_paraOptall, 9},
{"_GeoDiff_dnbinom_mu_vec", (DL_FUNC) &_GeoDiff_dnbinom_mu_vec, 4},
{NULL, NULL, 0}
};
RcppExport void R_init_GeoDiff(DllInfo *dll) {
R_registerRoutines(dll, NULL, CallEntries, NULL, NULL);
R_useDynamicSymbols(dll, FALSE);
}
|