diff --git a/pom.xml b/pom.xml
index 214e974..3144d48 100644
--- a/pom.xml
+++ b/pom.xml
@@ -3,14 +3,13 @@
4.0.0
edu.pitt.dbmi
causal-cmd
- 1.4.1
+ 1.4.2
jar
- 11
UTF-8
- 11
- 11
+ 1.8
+ 1.8
@@ -46,7 +45,7 @@
org.junit.jupiter
junit-jupiter-engine
- 5.8.2
+ 5.9.1
test
@@ -60,7 +59,7 @@
maven-resources-plugin
- 3.2.0
+ 3.3.0
copy-dist-resources
@@ -83,7 +82,7 @@
org.apache.maven.plugins
maven-jar-plugin
- 3.2.2
+ 3.3.0
@@ -95,7 +94,7 @@
org.apache.maven.plugins
maven-assembly-plugin
- 3.3.0
+ 3.4.2
package
@@ -134,7 +133,7 @@
org.apache.maven.plugins
maven-javadoc-plugin
- 3.4.0
+ 3.4.1
/usr/bin/javadoc
diff --git a/src/main/java/edu/pitt/dbmi/causal/cmd/Args.java b/src/main/java/edu/pitt/dbmi/causal/cmd/Args.java
index 1c8fd0a..1663dfe 100644
--- a/src/main/java/edu/pitt/dbmi/causal/cmd/Args.java
+++ b/src/main/java/edu/pitt/dbmi/causal/cmd/Args.java
@@ -72,7 +72,7 @@ public static String[] removeLongOption(String[] args, String option) {
}
}
- return argsToKeep.toArray(String[]::new);
+ return argsToKeep.stream().toArray(String[]::new);
}
/**
@@ -143,7 +143,7 @@ public static String[] extractLongOptions(String[] args, Options options) {
}
});
- return argsList.toArray(String[]::new);
+ return argsList.stream().toArray(String[]::new);
}
/**
@@ -179,7 +179,7 @@ public static String[] extractOptions(String[] args, Options options) {
}
});
- return argsList.toArray(String[]::new);
+ return argsList.stream().toArray(String[]::new);
}
/**
diff --git a/src/main/java/edu/pitt/dbmi/causal/cmd/CausalCmdApplication.java b/src/main/java/edu/pitt/dbmi/causal/cmd/CausalCmdApplication.java
index e02eac7..96b804e 100644
--- a/src/main/java/edu/pitt/dbmi/causal/cmd/CausalCmdApplication.java
+++ b/src/main/java/edu/pitt/dbmi/causal/cmd/CausalCmdApplication.java
@@ -137,7 +137,7 @@ private static void runTetrad(CmdArgs cmdArgs) throws AlgorithmRunException, Val
Files.deleteIfExists(outTxtFile);
}
- try ( PrintStream out = new PrintStream(new BufferedOutputStream(Files.newOutputStream(outTxtFile, StandardOpenOption.CREATE)), true)) {
+ try (PrintStream out = new PrintStream(new BufferedOutputStream(Files.newOutputStream(outTxtFile, StandardOpenOption.CREATE)), true)) {
writeOutParameters(cmdArgs, out);
if (!cmdArgs.isSkipValidation()) {
@@ -166,7 +166,7 @@ private static void runTetrad(CmdArgs cmdArgs) throws AlgorithmRunException, Val
Path outGraphFile = Paths.get(outDir, fileName);
if (Files.exists(outGraphFile)) {
- Files.deleteIfExists(outTxtFile);
+ Files.deleteIfExists(outGraphFile);
}
GraphIO.writeAsJSON(graphs[i], outGraphFile);
diff --git a/src/main/java/edu/pitt/dbmi/causal/cmd/CmdArgs.java b/src/main/java/edu/pitt/dbmi/causal/cmd/CmdArgs.java
index 9a9b538..80cf7d5 100644
--- a/src/main/java/edu/pitt/dbmi/causal/cmd/CmdArgs.java
+++ b/src/main/java/edu/pitt/dbmi/causal/cmd/CmdArgs.java
@@ -79,7 +79,7 @@ public class CmdArgs {
* by the data reader.
*/
protected String commentMarker;
-
+
/**
* Indicates whether the first line in the data file is a header.
*/
@@ -89,7 +89,7 @@ public class CmdArgs {
* Type of data in the dataset.
*/
protected DataType dataType;
-
+
/**
* Data delimiter.
*/
@@ -99,12 +99,12 @@ public class CmdArgs {
* Algorithm class.
*/
protected Class algorithmClass;
-
+
/**
* Score class.
*/
protected Class scoreClass;
-
+
/**
* Independence test class.
*/
@@ -119,14 +119,15 @@ public class CmdArgs {
* Indicates whether or not to skip data validation.
*/
protected boolean skipValidation;
-
+
/**
* Indicates whether to output the search graph in JSON format.
*/
protected boolean jsonGraph;
/**
- * Maximum number of threads can be used by algorithm, score, or independence test.
+ * Maximum number of threads can be used by algorithm, score, or
+ * independence test.
*/
protected int numOfThreads;
diff --git a/src/main/java/edu/pitt/dbmi/causal/cmd/CmdOptions.java b/src/main/java/edu/pitt/dbmi/causal/cmd/CmdOptions.java
index 834130a..c4bbc35 100644
--- a/src/main/java/edu/pitt/dbmi/causal/cmd/CmdOptions.java
+++ b/src/main/java/edu/pitt/dbmi/causal/cmd/CmdOptions.java
@@ -54,7 +54,7 @@ private CmdOptions() {
/**
* Get an instance of the command-line options.
*
- * @return
+ * @return CmdOptions instance
*/
public static CmdOptions getInstance() {
if (instance == null) {
@@ -75,7 +75,7 @@ public static void clear() {
* Get multi-character name options for a given name..
*
* @param param multi-character name
- * @return
+ * @return command-line option
*/
public Option getLongOption(String param) {
return options.get(param);
@@ -165,12 +165,11 @@ public List