[GitHub] spark pull request #23256: [SPARK-24207][R] follow-up PR for SPARK-24207 to ...

2018-12-08 Thread asfgit
Github user asfgit closed the pull request at:

https://github.com/apache/spark/pull/23256


---

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



[GitHub] spark pull request #23256: [SPARK-24207][R] follow-up PR for SPARK-24207 to ...

2018-12-07 Thread felixcheung
Github user felixcheung commented on a diff in the pull request:

https://github.com/apache/spark/pull/23256#discussion_r239997109
  
--- Diff: R/pkg/tests/fulltests/test_mllib_fpm.R ---
@@ -84,19 +84,20 @@ test_that("spark.fpGrowth", {
 })
 
 test_that("spark.prefixSpan", {
-df <- createDataFrame(list(list(list(list(1L, 2L), list(3L))),
-  list(list(list(1L), list(3L, 2L), list(1L, 2L))),
-  list(list(list(1L, 2L), list(5L))),
-  list(list(list(6L, schema = c("sequence"))
-result1 <- spark.findFrequentSequentialPatterns(df, minSupport = 0.5, 
maxPatternLength = 5L,
-maxLocalProjDBSize = 
3200L)
-
-expected_result <- createDataFrame(list(list(list(list(1L)), 3L),
-list(list(list(3L)), 2L),
-list(list(list(2L)), 3L),
-list(list(list(1L, 2L)), 3L),
-list(list(list(1L), list(3L)), 
2L)),
-schema = c("sequence", "freq"))
-  })
+  df <- createDataFrame(list(list(list(list(1L, 2L), list(3L))),
+ list(list(list(1L), list(3L, 2L), list(1L, 
2L))),
+ list(list(list(1L, 2L), list(5L))),
+ list(list(list(6L,
+schema = c("sequence"))
+  result <- spark.findFrequentSequentialPatterns(df, minSupport = 0.5, 
maxPatternLength = 5L,
+ maxLocalProjDBSize = 
3200L)
+
+  expected_result <- createDataFrame(list(list(list(list(1L)), 3L), 
list(list(list(3L)), 2L),
+  list(list(list(2L)), 3L), 
list(list(list(1L, 2L)), 3L),
+  list(list(list(1L), list(3L)), 
2L)),
+ schema = c("sequence", "freq"))
+
+  expect_equivalent(expected_result, result)
--- End diff --

this is an important fix..


---

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



[GitHub] spark pull request #23256: [SPARK-24207][R] follow-up PR for SPARK-24207 to ...

2018-12-07 Thread huaxingao
GitHub user huaxingao opened a pull request:

https://github.com/apache/spark/pull/23256

[SPARK-24207][R] follow-up PR for SPARK-24207 to fix code style problems

## What changes were proposed in this pull request?

follow-up PR for SPARK-24207 to fix code style problems

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/huaxingao/spark spark-24207-cnt

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/spark/pull/23256.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #23256


commit 04ec3e18e71b0f0e0d212a3532a6dc06518d61c0
Author: Huaxin Gao 
Date:   2018-12-07T19:55:50Z

fix code style problems




---

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