nealrichardson commented on a change in pull request #10689:
URL: https://github.com/apache/arrow/pull/10689#discussion_r670607551



##########
File path: r/R/dplyr-functions.R
##########
@@ -559,3 +559,21 @@ nse_funcs$wday <- function(x, label = FALSE, abbr = TRUE, 
week_start = getOption
   Expression$create("day_of_week", x, options = list(one_based_numbering = 
TRUE, week_start = week_start))
 
 }
+
+nse_funcs$log <- function(x, base = exp(1)) {
+  
+  if (base == exp(1)) {
+    return(Expression$create("ln_checked", x))
+  }
+  
+  if (base == 2) {
+    return(Expression$create("log2_checked", x))
+  }
+  
+  if (base == 10) {
+    return(Expression$create("log10_checked", x))
+  } 
+  stop("`base` values other than exp(1), 2 and 10 not supported in Arrow")

Review comment:
       ```suggestion
     # ARROW-13345
     stop("`base` values other than exp(1), 2 and 10 not supported in Arrow")
   ```




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscr...@arrow.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to