-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMainTestHUIMiner.java
More file actions
34 lines (25 loc) · 944 Bytes
/
Copy pathMainTestHUIMiner.java
File metadata and controls
34 lines (25 loc) · 944 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
package ca.pfv.spmf.test;
import java.io.IOException;
import java.io.UnsupportedEncodingException;
import java.net.URL;
import ca.pfv.spmf.algorithms.frequentpatterns.hui_miner.AlgoHUIMiner;
/**
* Example of how to use the HUIMiner algorithm
* from the source code.
* @author Philippe Fournier-Viger, 2010
*/
public class MainTestHUIMiner {
public static void main(String [] arg) throws IOException{
String input = fileToPath("DB_Utility.txt");
String output = ".//output.txt";
int min_utility = 1045203; //
// Applying the HUIMiner algorithm
AlgoHUIMiner huiminer = new AlgoHUIMiner();
huiminer.runAlgorithm(input, output, min_utility);
huiminer.printStats();
}
public static String fileToPath(String filename) throws UnsupportedEncodingException{
URL url = MainTestHUIMiner.class.getResource(filename);
return java.net.URLDecoder.decode(url.getPath(),"UTF-8");
}
}