Skip to content
  • Yanbo Liang's avatar
    9cb3ba10
    [SPARK-14312][ML][SPARKR] NaiveBayes model persistence in SparkR · 9cb3ba10
    Yanbo Liang authored
    ## What changes were proposed in this pull request?
    SparkR ```NaiveBayesModel``` supports ```save/load``` by the following API:
    ```
    df <- createDataFrame(sqlContext, infert)
    model <- naiveBayes(education ~ ., df, laplace = 0)
    ml.save(model, path)
    model2 <- ml.load(path)
    ```
    
    ## How was this patch tested?
    Add unit tests.
    
    cc mengxr
    
    Author: Yanbo Liang <ybliang8@gmail.com>
    
    Closes #12573 from yanboliang/spark-14312.
    9cb3ba10
    [SPARK-14312][ML][SPARKR] NaiveBayes model persistence in SparkR
    Yanbo Liang authored
    ## What changes were proposed in this pull request?
    SparkR ```NaiveBayesModel``` supports ```save/load``` by the following API:
    ```
    df <- createDataFrame(sqlContext, infert)
    model <- naiveBayes(education ~ ., df, laplace = 0)
    ml.save(model, path)
    model2 <- ml.load(path)
    ```
    
    ## How was this patch tested?
    Add unit tests.
    
    cc mengxr
    
    Author: Yanbo Liang <ybliang8@gmail.com>
    
    Closes #12573 from yanboliang/spark-14312.
Loading