File tree Expand file tree Collapse file tree 1 file changed +12
-0
lines changed
mllib/src/main/scala/org/apache/spark/mllib/fpm Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -53,6 +53,12 @@ class PrefixSpan private (
5353 */
5454 def this () = this (0.1 , 10 )
5555
56+ /**
57+ * Get the minimal support (i.e. the frequency of occurrence before a pattern is considered
58+ * frequent).
59+ */
60+ def getMinSupport (): Double = this .minSupport
61+
5662 /**
5763 * Sets the minimal support level (default: `0.1`).
5864 */
@@ -63,10 +69,16 @@ class PrefixSpan private (
6369 this
6470 }
6571
72+ /**
73+ * Gets the maximal pattern length (i.e. the length of the longest sequential pattern to consider.
74+ */
75+ def getMaxPatternLength (): Double = this .maxPatternLength
76+
6677 /**
6778 * Sets maximal pattern length (default: `10`).
6879 */
6980 def setMaxPatternLength (maxPatternLength : Int ): this .type = {
81+ // TODO: support unbounded pattern length when maxPatternLength = 0
7082 require(maxPatternLength >= 1 ,
7183 " The maximum pattern length value must be greater than 0." )
7284 this .maxPatternLength = maxPatternLength
You can’t perform that action at this time.
0 commit comments