You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by actuaryzhang <gi...@git.apache.org> on 2017/05/18 06:58:19 UTC

[GitHub] spark issue #18025: [WIP][SparkR] Update doc and examples for sql functions

Github user actuaryzhang commented on the issue:

    https://github.com/apache/spark/pull/18025
  
    @felixcheung @HyukjinKwon 
    
    Per this [suggestion](https://github.com/apache/spark/pull/18003#discussion-diff-116853922L57), I'm creating more meaningful examples for the SQL functions. 
    
    Since these functions can be grouped, we can create a single page doc for each group of the functions and construct concrete and useful examples for each group. The benefit is obvious:
    -  Centralized documentation of related functions. This makes it easier for user to navigate. Right now there are TOO many items in the `see also` section. 
    -  Examples can share the same data. This avoids creating a data frame for each function if they are documented separately.
    - Cleaner structure and much fewer Rd files.
    
    Indeed, this is part of what was discussed in #17161. I have explored this for a few functions to illustrate the idea. Since this is a big effort, I would like to get folks' opinions before extending this to all functions. 
    
    In this commit, I created docs for some sample functions in three groups:
    -  'column_datetime_functions' to document all datetime functions
    -  'column_aggregate_functions' to document all aggregate functions
    -  'column_math_functions' to document all math functions
    -  ...
    
    Below is what 'column_datetime_functions.Rd' looks like:
    
    ![image](https://cloud.githubusercontent.com/assets/11082368/26189797/426029f0-3b5b-11e7-9175-c63b0e5c0014.png)
    ![image](https://cloud.githubusercontent.com/assets/11082368/26189810/56630954-3b5b-11e7-9d70-3e74b6d3b032.png)



---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org