Skip to content

Commit

Permalink
Updated manuals with the new parameters and manuals for new functions
Browse files Browse the repository at this point in the history
  • Loading branch information
LHBO committed Dec 18, 2024
1 parent 6af3c1e commit e0ec963
Show file tree
Hide file tree
Showing 5 changed files with 39 additions and 8 deletions.
7 changes: 5 additions & 2 deletions R/RcppExports.R
Original file line number Diff line number Diff line change
Expand Up @@ -241,8 +241,11 @@ sample_features_cpp <- function(m, n_features) {
.Call(`_shapr_sample_features_cpp`, m, n_features)
}

#' We here return a list of strings, where each string is a comma-separated list of integers, but the structure
#' could also have been a CharacterVector. The reason for using a list here is that sample_features_cpp returns a list.
#' We here return a vector of strings/characters, i.e., a CharacterVector,
#' where each string is a space-separated list of integers.
#' @param m Integer The number of elements to sample from, i.e., the number of features.
#' @param n_features IntegerVector The number of features to sample for each feature combination.
#' @param paired_shap_sampling Logical Should we return both the sampled coalition S and its complement Sbar.
#' @keywords internal
sample_features_cpp_str_paired <- function(m, n_features, paired_shap_sampling = TRUE) {
.Call(`_shapr_sample_features_cpp_str_paired`, m, n_features, paired_shap_sampling)
Expand Down
10 changes: 7 additions & 3 deletions man/create_coalition_table.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion man/get_iterative_args_default.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

21 changes: 21 additions & 0 deletions man/sample_features_cpp_str_paired.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 5 additions & 2 deletions src/features.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,11 @@ List sample_features_cpp(int m, IntegerVector n_features) {
return l;
}

//' We here return a list of strings, where each string is a comma-separated list of integers, but the structure
//' could also have been a CharacterVector. The reason for using a list here is that sample_features_cpp returns a list.
//' We here return a vector of strings/characters, i.e., a CharacterVector,
//' where each string is a space-separated list of integers.
//' @param m Integer The number of elements to sample from, i.e., the number of features.
//' @param n_features IntegerVector The number of features to sample for each feature combination.
//' @param paired_shap_sampling Logical Should we return both the sampled coalition S and its complement Sbar.
//' @keywords internal
// [[Rcpp::export]]
CharacterVector sample_features_cpp_str_paired(int m, IntegerVector n_features, bool paired_shap_sampling = true) {
Expand Down

0 comments on commit e0ec963

Please sign in to comment.