Quatargo exercise - modify existing package - Zoltan#8
Quatargo exercise - modify existing package - Zoltan#8zoltanszebenyi wants to merge 8 commits intoquantargo:masterfrom
Conversation
Codecov Report
@@ Coverage Diff @@
## master #8 +/- ##
=========================================
Coverage ? 18.18%
=========================================
Files ? 3
Lines ? 11
Branches ? 0
=========================================
Hits ? 2
Misses ? 9
Partials ? 0
Continue to review full report at Codecov.
|
mannau
left a comment
There was a problem hiding this comment.
Great work!
Just found some minor issues regarding the function descriptions and edge cases in the windsorize function.
| @@ -1 +1,2 @@ | |||
| exportPattern("^[[:alpha:]]+") | |||
| importFrom("stats", "quantile") No newline at end of file | |||
There was a problem hiding this comment.
Why haven't you used the package roxygen2 to generate the NAMESPACE file?
| @@ -1,4 +1,6 @@ | |||
| #' Meanimputation | |||
| #' @param x A vector. | |||
| @@ -0,0 +1,16 @@ | |||
| #' Transform_log | |||
| #' | |||
| #' Log transformation. | |||
There was a problem hiding this comment.
Description could be longer here.
| #' | ||
| #' Do some windsorization. | ||
| #' | ||
| #' Winsorizing or winsorization is the transformation of statistics by limiting |
There was a problem hiding this comment.
Nice description! Just missing how input parameter p influences the result
| q <- quantile(x, p) | ||
| x[x >= q] <- q | ||
| if(all(is.na(x))) {stop("argument should not be a vector containing only NA-s or NULL-s")} | ||
| q_up <- quantile(x, 0.5 + p / 2 ) |
There was a problem hiding this comment.
Try to consider the following situations:
- What happens if
xcontains someNAvalues? - What happens if
xis an empty/NULL vector?
No description provided.