Skip to content

Commit

Permalink
removed unnecessary export
Browse files Browse the repository at this point in the history
  • Loading branch information
schochastics committed Jan 12, 2024
1 parent cb09599 commit 161613c
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 126 deletions.
28 changes: 0 additions & 28 deletions R/RcppExports.R
Original file line number Diff line number Diff line change
Expand Up @@ -48,34 +48,6 @@ dendrogram_spread <- function(graph, starts, y, leaf, repel, pad, ratio) {
.Call('_ggraph_dendrogram_spread', PACKAGE = 'ggraph', graph, starts, y, leaf, repel, pad, ratio)
}

euclidean_distance <- function(P, Q) {
.Call('_ggraph_euclidean_distance', PACKAGE = 'ggraph', P, Q)
}

angle_compatibility <- function(P, Q) {
.Call('_ggraph_angle_compatibility', PACKAGE = 'ggraph', P, Q)
}

scale_compatibility <- function(P, Q) {
.Call('_ggraph_scale_compatibility', PACKAGE = 'ggraph', P, Q)
}

position_compatibility <- function(P, Q) {
.Call('_ggraph_position_compatibility', PACKAGE = 'ggraph', P, Q)
}

visibility_compatibility <- function(P, Q) {
.Call('_ggraph_visibility_compatibility', PACKAGE = 'ggraph', P, Q)
}

compatibility_score <- function(P, Q) {
.Call('_ggraph_compatibility_score', PACKAGE = 'ggraph', P, Q)
}

compute_compatibility_lists <- function(edges_xy, compatibility_threshold) {
.Call('_ggraph_compute_compatibility_lists', PACKAGE = 'ggraph', edges_xy, compatibility_threshold)
}

force_bundle_iter <- function(edges_xy, elist, K, C, P, P_rate, S, I, I_rate, compatibility_threshold, eps) {
.Call('_ggraph_force_bundle_iter', PACKAGE = 'ggraph', edges_xy, elist, K, C, P, P_rate, S, I, I_rate, compatibility_threshold, eps)
}
Expand Down
91 changes: 0 additions & 91 deletions src/RcppExports.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -50,90 +50,6 @@ BEGIN_RCPP
return rcpp_result_gen;
END_RCPP
}
// euclidean_distance
double euclidean_distance(NumericVector P, NumericVector Q);
RcppExport SEXP _ggraph_euclidean_distance(SEXP PSEXP, SEXP QSEXP) {
BEGIN_RCPP
Rcpp::RObject rcpp_result_gen;
Rcpp::RNGScope rcpp_rngScope_gen;
Rcpp::traits::input_parameter< NumericVector >::type P(PSEXP);
Rcpp::traits::input_parameter< NumericVector >::type Q(QSEXP);
rcpp_result_gen = Rcpp::wrap(euclidean_distance(P, Q));
return rcpp_result_gen;
END_RCPP
}
// angle_compatibility
double angle_compatibility(NumericVector P, NumericVector Q);
RcppExport SEXP _ggraph_angle_compatibility(SEXP PSEXP, SEXP QSEXP) {
BEGIN_RCPP
Rcpp::RObject rcpp_result_gen;
Rcpp::RNGScope rcpp_rngScope_gen;
Rcpp::traits::input_parameter< NumericVector >::type P(PSEXP);
Rcpp::traits::input_parameter< NumericVector >::type Q(QSEXP);
rcpp_result_gen = Rcpp::wrap(angle_compatibility(P, Q));
return rcpp_result_gen;
END_RCPP
}
// scale_compatibility
double scale_compatibility(NumericVector P, NumericVector Q);
RcppExport SEXP _ggraph_scale_compatibility(SEXP PSEXP, SEXP QSEXP) {
BEGIN_RCPP
Rcpp::RObject rcpp_result_gen;
Rcpp::RNGScope rcpp_rngScope_gen;
Rcpp::traits::input_parameter< NumericVector >::type P(PSEXP);
Rcpp::traits::input_parameter< NumericVector >::type Q(QSEXP);
rcpp_result_gen = Rcpp::wrap(scale_compatibility(P, Q));
return rcpp_result_gen;
END_RCPP
}
// position_compatibility
double position_compatibility(NumericVector P, NumericVector Q);
RcppExport SEXP _ggraph_position_compatibility(SEXP PSEXP, SEXP QSEXP) {
BEGIN_RCPP
Rcpp::RObject rcpp_result_gen;
Rcpp::RNGScope rcpp_rngScope_gen;
Rcpp::traits::input_parameter< NumericVector >::type P(PSEXP);
Rcpp::traits::input_parameter< NumericVector >::type Q(QSEXP);
rcpp_result_gen = Rcpp::wrap(position_compatibility(P, Q));
return rcpp_result_gen;
END_RCPP
}
// visibility_compatibility
double visibility_compatibility(NumericVector P, NumericVector Q);
RcppExport SEXP _ggraph_visibility_compatibility(SEXP PSEXP, SEXP QSEXP) {
BEGIN_RCPP
Rcpp::RObject rcpp_result_gen;
Rcpp::RNGScope rcpp_rngScope_gen;
Rcpp::traits::input_parameter< NumericVector >::type P(PSEXP);
Rcpp::traits::input_parameter< NumericVector >::type Q(QSEXP);
rcpp_result_gen = Rcpp::wrap(visibility_compatibility(P, Q));
return rcpp_result_gen;
END_RCPP
}
// compatibility_score
double compatibility_score(NumericVector P, NumericVector Q);
RcppExport SEXP _ggraph_compatibility_score(SEXP PSEXP, SEXP QSEXP) {
BEGIN_RCPP
Rcpp::RObject rcpp_result_gen;
Rcpp::RNGScope rcpp_rngScope_gen;
Rcpp::traits::input_parameter< NumericVector >::type P(PSEXP);
Rcpp::traits::input_parameter< NumericVector >::type Q(QSEXP);
rcpp_result_gen = Rcpp::wrap(compatibility_score(P, Q));
return rcpp_result_gen;
END_RCPP
}
// compute_compatibility_lists
List compute_compatibility_lists(NumericMatrix edges_xy, double compatibility_threshold);
RcppExport SEXP _ggraph_compute_compatibility_lists(SEXP edges_xySEXP, SEXP compatibility_thresholdSEXP) {
BEGIN_RCPP
Rcpp::RObject rcpp_result_gen;
Rcpp::RNGScope rcpp_rngScope_gen;
Rcpp::traits::input_parameter< NumericMatrix >::type edges_xy(edges_xySEXP);
Rcpp::traits::input_parameter< double >::type compatibility_threshold(compatibility_thresholdSEXP);
rcpp_result_gen = Rcpp::wrap(compute_compatibility_lists(edges_xy, compatibility_threshold));
return rcpp_result_gen;
END_RCPP
}
// force_bundle_iter
List force_bundle_iter(NumericMatrix edges_xy, List elist, double K, int C, int P, int P_rate, double S, int I, double I_rate, double compatibility_threshold, double eps);
RcppExport SEXP _ggraph_force_bundle_iter(SEXP edges_xySEXP, SEXP elistSEXP, SEXP KSEXP, SEXP CSEXP, SEXP PSEXP, SEXP P_rateSEXP, SEXP SSEXP, SEXP ISEXP, SEXP I_rateSEXP, SEXP compatibility_thresholdSEXP, SEXP epsSEXP) {
Expand Down Expand Up @@ -237,13 +153,6 @@ static const R_CallMethodDef CallEntries[] = {
{"_ggraph_pack", (DL_FUNC) &_ggraph_pack, 1},
{"_ggraph_circlePackLayout", (DL_FUNC) &_ggraph_circlePackLayout, 2},
{"_ggraph_dendrogram_spread", (DL_FUNC) &_ggraph_dendrogram_spread, 7},
{"_ggraph_euclidean_distance", (DL_FUNC) &_ggraph_euclidean_distance, 2},
{"_ggraph_angle_compatibility", (DL_FUNC) &_ggraph_angle_compatibility, 2},
{"_ggraph_scale_compatibility", (DL_FUNC) &_ggraph_scale_compatibility, 2},
{"_ggraph_position_compatibility", (DL_FUNC) &_ggraph_position_compatibility, 2},
{"_ggraph_visibility_compatibility", (DL_FUNC) &_ggraph_visibility_compatibility, 2},
{"_ggraph_compatibility_score", (DL_FUNC) &_ggraph_compatibility_score, 2},
{"_ggraph_compute_compatibility_lists", (DL_FUNC) &_ggraph_compute_compatibility_lists, 2},
{"_ggraph_force_bundle_iter", (DL_FUNC) &_ggraph_force_bundle_iter, 11},
{"_ggraph_partitionTree", (DL_FUNC) &_ggraph_partitionTree, 4},
{"_ggraph_cut_lines", (DL_FUNC) &_ggraph_cut_lines, 9},
Expand Down
7 changes: 0 additions & 7 deletions src/forceBundle.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
#include <Rcpp.h>
using namespace Rcpp;

// [[Rcpp::export]]
double euclidean_distance(NumericVector P, NumericVector Q) {
return sqrt((P[0] - Q[0]) * (P[0] - Q[0]) + (P[1] - Q[1]) * (P[1] - Q[1]));
}
Expand Down Expand Up @@ -124,7 +123,6 @@ List update_edge_divisions(List elist, int P) {
return elist;
}

// [[Rcpp::export]]
double angle_compatibility(NumericVector P, NumericVector Q) {
NumericVector P_source = {P[0], P[1]};
NumericVector P_target = {P[2], P[3]};
Expand All @@ -138,7 +136,6 @@ double angle_compatibility(NumericVector P, NumericVector Q) {
return std::abs(frac_PQ);
}

// [[Rcpp::export]]
double scale_compatibility(NumericVector P, NumericVector Q) {
NumericVector P_source = {P[0], P[1]};
NumericVector P_target = {P[2], P[3]};
Expand All @@ -152,7 +149,6 @@ double scale_compatibility(NumericVector P, NumericVector Q) {
return 2.0 / (lavg / std::min(euc_P, euc_Q) + std::max(euc_P, euc_Q) / lavg);
}

// [[Rcpp::export]]
double position_compatibility(NumericVector P, NumericVector Q) {
NumericVector P_source = {P[0], P[1]};
NumericVector P_target = {P[2], P[3]};
Expand All @@ -174,12 +170,10 @@ double position_compatibility(NumericVector P, NumericVector Q) {
return lavg / (lavg + euc_mid);
}

// [[Rcpp::export]]
double visibility_compatibility(NumericVector P, NumericVector Q) {
return std::min(edge_visibility(P, Q), edge_visibility(Q, P));
}

// [[Rcpp::export]]
double compatibility_score(NumericVector P, NumericVector Q) {
return angle_compatibility(P, Q) * scale_compatibility(P, Q) *
position_compatibility(P, Q) * visibility_compatibility(P, Q);
Expand All @@ -190,7 +184,6 @@ bool are_compatible(NumericVector P, NumericVector Q,
return compatibility_score(P, Q) >= compatibility_threshold;
}

// [[Rcpp::export]]
List compute_compatibility_lists(NumericMatrix edges_xy,
double compatibility_threshold) {
int m = edges_xy.rows();
Expand Down

0 comments on commit 161613c

Please sign in to comment.