Skip to content

Commit

Permalink
Fixed MADMMplasso(parallel, !pal, !legacy) (#17)
Browse files Browse the repository at this point in the history
  • Loading branch information
wleoncio committed Jun 24, 2024
1 parent 87080e7 commit 8d52663
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions src/hh_nlambda_loop_cpp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -53,12 +53,13 @@ Rcpp::List hh_nlambda_loop_cpp(

if (parallel) { // TODO: recheck all conditions (all parallel-pal combinations)
// my_values is already a list of length hh
beta0 = my_values[hh]["beta0"];
theta0 = my_values[hh]["theta0"];
beta = my_values[hh]["beta"];
theta = my_values[hh]["theta"];
beta_hat = my_values[hh]["beta_hat"];
y_hat = my_values[hh]["y_hat"];
arma::field<arma::cube> my_values_hh = my_values[hh];
beta0 = my_values_hh(0).slice(0);
theta0 = my_values_hh(1).slice(0);
beta = my_values_hh(2).slice(0);
theta = my_values_hh(3);
beta_hat = my_values_hh(5).slice(0);
y_hat = my_values_hh(6).slice(0);
} else if (pal) {
// In this case, my_values is an empty list to be created now
arma::field<arma::cube> my_values_hh = admm_MADMMplasso_cpp(
Expand Down

0 comments on commit 8d52663

Please sign in to comment.