From: Thomas <170013569@dundee.ac.uk> Date: Fri, 12 Jul 2019 14:46:32 +0000 (+0100) Subject: JAL-2629 can now choose number of jackhmmer iterations X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=5cb4c1540eaca054c26ff42a8319f0dbffb1f8e6;p=jalview.git JAL-2629 can now choose number of jackhmmer iterations --- diff --git a/resources/lang/Messages.properties b/resources/lang/Messages.properties index 2c0fbb9..b627ac8 100644 --- a/resources/lang/Messages.properties +++ b/resources/lang/Messages.properties @@ -1380,6 +1380,7 @@ label.executable_not_found = The ''{0}'' executable file was not found warn.command_failed = {0} failed label.invalid_folder = Invalid Folder label.number_of_results = Number of Results to Return +label.number_of_iterations = Number of jackhmmer Iterations label.auto_align_seqs = Automatically Align Fetched Sequences label.new_returned = new sequences returned label.use_accessions = Return Accessions @@ -1394,6 +1395,7 @@ label.inclusion_seq_score = Inclusion Sequence Score Threshold label.inclusion_dom_evalue = Inclusion Domain E-value Cut-off label.inclusion_dom_score = Inclusion Domain Score Threshold label.number_of_results_desc = The maximum number of hmmsearch results to display +label.number_of_iterations_desc = The number of iterations jackhmmer will complete when searching for new sequences label.auto_align_seqs_desc = If true, all fetched sequences will be aligned to the hidden Markov model with which the search was performed label.check_for_new_sequences_desc = Display number of new sequences returned from hmmsearch compared to the previous alignment label.use_accessions_desc = If true, the accession number of each sequence is returned, rather than that sequence's name diff --git a/src/jalview/hmmer/HMMERParamStore.java b/src/jalview/hmmer/HMMERParamStore.java index be03ec5..df9ab55 100644 --- a/src/jalview/hmmer/HMMERParamStore.java +++ b/src/jalview/hmmer/HMMERParamStore.java @@ -221,6 +221,10 @@ public final class HMMERParamStore implements ParamDatastoreI String database = MessageManager.getString("label.database"); args.add(new FileParameter(database, "", false, "", "")); + args.add(new IntegerParameter( + MessageManager.getString(HMMSearch.NUMBER_OF_ITERATIONS), + MessageManager.getString("label.number_of_iterations_desc"), + true, 5, 1, 20)); args.add(new RadioChoiceParameter( MessageManager.getString(JackHMMER.REPORTING_CUTOFF_KEY), null, Arrays.asList(MessageManager.getString(JackHMMER.CUTOFF_NONE), diff --git a/src/jalview/hmmer/HmmerCommand.java b/src/jalview/hmmer/HmmerCommand.java index f38be02..b311b76 100644 --- a/src/jalview/hmmer/HmmerCommand.java +++ b/src/jalview/hmmer/HmmerCommand.java @@ -60,6 +60,8 @@ public abstract class HmmerCommand implements Runnable static final String NUMBER_OF_RESULTS_KEY = "label.number_of_results"; + static final String NUMBER_OF_ITERATIONS = "label.number_of_iterations"; + static final String TRIM_TERMINI_KEY = "label.trim_termini"; static final String RETURN_N_NEW_SEQ = "label.check_for_new_sequences"; diff --git a/src/jalview/hmmer/Search.java b/src/jalview/hmmer/Search.java index 5c7da7c..ceb79e5 100644 --- a/src/jalview/hmmer/Search.java +++ b/src/jalview/hmmer/Search.java @@ -329,6 +329,15 @@ public abstract class Search extends HmmerCommand searchAlignment = false; } } + else if (MessageManager.getString(NUMBER_OF_ITERATIONS) + .equals(name)) + { + if (!arg.getValue().isEmpty()) + { + args.add("-N"); + args.add(arg.getValue()); + } + } } }