Skip to content

Commit

Permalink
Fixed typos
Browse files Browse the repository at this point in the history
  • Loading branch information
wleoncio committed Jan 2, 2025
1 parent f70c4a7 commit 942bf79
Show file tree
Hide file tree
Showing 9 changed files with 14 additions and 14 deletions.
2 changes: 1 addition & 1 deletion R/MADMMplasso.R
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
#' @param rho the Lagrange variable for the ADMM. This value is updated during the ADMM call based on a certain condition.
#' @param e.abs absolute error for the ADMM
#' @param e.rel relative error for the ADMM
#' @param gg penalty term for the tree structure. This is a 2x2 matrix values in the first row representing the maximum to the minimum values for lambda_1 and the second row representing the maximum to the minimum values for lambda_2. In the current setting, we set both maximum and the minimum to be same because cross validation is not carried across the lambda_1 and lambda_2. However, setting different values will work during the model fit.
#' @param gg penalty term for the tree structure. This is a 2×2 matrix values in the first row representing the maximum to the minimum values for lambda_1 and the second row representing the maximum to the minimum values for lambda_2. In the current setting, we set both maximum and the minimum to be same because cross validation is not carried across the lambda_1 and lambda_2. However, setting different values will work during the model fit.
#' @param my_lambda user specified lambda_3 values
#' @param lambda_min the smallest value for lambda_3 , as a fraction of max(lambda_3), the (data derived (lammax)) entry value (i.e. the smallest value for which all coefficients are zero)
#' @param max_it maximum number of iterations in loop for one lambda during the ADMM optimization
Expand Down
2 changes: 1 addition & 1 deletion R/admm_MADMMplasso.R
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
#' @param N nrow(X)
#' @param svd.w singular value decomposition of W
#' @param invmat A list of length ncol(y), each containing the C_d part of equation 32 in the paper
#' @param gg penalty terms for the tree structure for lambda_1 and lambda_2 for the admm call.
#' @param gg penalty terms for the tree structure for lambda_1 and lambda_2 for the ADMM call.
#' @return predicted values for the ADMM part

#' beta0: estimated beta_0 coefficients having a size of 1 by ncol(y)
Expand Down
2 changes: 1 addition & 1 deletion R/tree_parms.R
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
#' @param y N by D matrix of response variables
#' @param h is the tree cut off
#' @return A trained tree with the following components:
#' Tree: the tree matrix stored in 1's and 0's
#' Tree: the tree matrix stored in 1s and 0s
#' Tw: tree weights associated with the tree matrix. Each weight corresponds to a row in the tree matrix.
#' h_clust: Summary of the hclust call
#' y.colnames: names of the response
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

Multi variate multi-response 'ADMM' with interaction effects combines the usual squared error loss for the mult-response problem with some penalty terms to encourage responses that correlate to form groups and also allow for modeling main and interaction effects that exit within the covariates.

The method can be powperful in situations where one assumes that;
1. certain factors influence the main covariate seperatly and aims to include these fatcors as modifying varibles to the main covariate.
The method can be powerful in situations where one assumes that;
1. certain factors influence the main covariate separately and aims to include these factors as modifying variables to the main covariate.
2. There exists some form of grouping within the responses and want to include this information. We assume that the responses form overlapping groups that follows a certain hierarchy.
A typical example is when one wants to model drug response for multiple drugs and assumes that some of the drugs share certain properties in common, for example drug target and chemical compounds and aims to include this information to improve prediction and also aim to predict which drug could be suitable for which patient (given a particular disease). The various diseases under study could be the modifying variable.

Expand Down Expand Up @@ -65,7 +65,7 @@ TT <- tree_parms(y)
plot(TT$h_clust)
```

![githubb](https://github.com/ocbe-uio/MADMMplasso/assets/85598983/1a843b46-7154-405c-8db6-cec5b7a0982d)
![github](https://github.com/ocbe-uio/MADMMplasso/assets/85598983/1a843b46-7154-405c-8db6-cec5b7a0982d)

```r
gg1 <- matrix(0,2,2)
Expand Down
2 changes: 1 addition & 1 deletion man/MADMMplasso.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/admm_MADMMplasso_cpp.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/cv_MADMMplasso.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/tree_parms.Rd

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

8 changes: 4 additions & 4 deletions src/admm_MADMMplasso.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@
//' @param XtY a matrix formed by multiplying the transpose of X by y.
//' @param y N by D matrix of responses. The X and Z variables are centered in the function. We recommend that X and Z also be standardized before the call
//' @param N nrow(X)
//' @param e_abs absolute error for the admm. This is included int the call of MADMMplasso.
//' @param e_rel relative error for the admm. This is included int the call of MADMMplasso.
//' @param e_abs absolute error for the ADMM. This is included int the call of MADMMplasso.
//' @param e_rel relative error for the ADMM. This is included int the call of MADMMplasso.
//' @param alpha mixing parameter, usually obtained from the MADMMplasso call. When the goal is to include more interactions, alpha should be very small and vice versa.
//' @param lambda a vector lambda_3 values for the admm call with length ncol(y). This is usually calculated in the MADMMplasso call. In our current setting, we use the same the lambda_3 value for all responses.
//' @param lambda a vector lambda_3 values for the ADMM call with length ncol(y). This is usually calculated in the MADMMplasso call. In our current setting, we use the same the lambda_3 value for all responses.
//' @param alph an overrelaxation parameter in \[1, 1.8\], usually obtained from the MADMMplasso call.
//' @param svd_w_tu the transpose of the U matrix from the SVD of W_hat
//' @param svd_w_tv the transpose of the V matrix from the SVD of W_hat
Expand All @@ -32,7 +32,7 @@
//' The easy way to obtain this is by using the function (tree_parms) which gives a default clustering.
//' However, user decide on a specific structure and then input a tree that follows such structure.
//' @param my_print Should information form each ADMM iteration be printed along the way? Default TRUE. This prints the dual and primal residuals
//' @param gg penalty terms for the tree structure for lambda_1 and lambda_2 for the admm call.
//' @param gg penalty terms for the tree structure for lambda_1 and lambda_2 for the ADMM call.
//' @return predicted values for the ADMM part
//' @description This function fits a multi-response pliable lasso model over a path of regularization values.
//' @export
Expand Down

0 comments on commit 942bf79

Please sign in to comment.