<classpathentry kind="lib" path="lib/biojava-core-4.1.0.jar"/>
<classpathentry kind="lib" path="lib/biojava-ontology-4.1.0.jar"/>
<classpathentry kind="lib" path="lib/groovy-all-2.4.6-indy.jar"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/forester"/>
<classpathentry kind="output" path="classes"/>
</classpath>
<name>Jalview Release 2.7</name>
<comment></comment>
<projects>
+ <project>forester</project>
</projects>
<buildSpec>
<buildCommand>
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
org.eclipse.jdt.core.compiler.source=1.7
+org.eclipse.jdt.core.formatter.align_fields_grouping_blank_lines=2147483647
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=52
org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
org.eclipse.jdt.core.formatter.alignment_for_enum_constants=16
org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
+org.eclipse.jdt.core.formatter.alignment_for_expressions_in_for_loop_header=0
org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
+org.eclipse.jdt.core.formatter.alignment_for_parameterized_type_references=0
org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_type_arguments=0
+org.eclipse.jdt.core.formatter.alignment_for_type_parameters=0
org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
org.eclipse.jdt.core.formatter.blank_lines_after_package=1
org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=next_line
org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
+org.eclipse.jdt.core.formatter.comment.count_line_length_from_starting_position=false
org.eclipse.jdt.core.formatter.comment.format_block_comments=false
org.eclipse.jdt.core.formatter.comment.format_header=false
org.eclipse.jdt.core.formatter.comment.format_html=true
org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
org.eclipse.jdt.core.formatter.indentation.size=8
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_enum_constant=insert
org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
+org.eclipse.jdt.core.formatter.parentheses_positions_in_annotation=common_lines
+org.eclipse.jdt.core.formatter.parentheses_positions_in_catch_clause=common_lines
+org.eclipse.jdt.core.formatter.parentheses_positions_in_enum_constant_declaration=common_lines
+org.eclipse.jdt.core.formatter.parentheses_positions_in_for_statment=common_lines
+org.eclipse.jdt.core.formatter.parentheses_positions_in_if_while_statement=common_lines
+org.eclipse.jdt.core.formatter.parentheses_positions_in_lambda_declaration=common_lines
+org.eclipse.jdt.core.formatter.parentheses_positions_in_method_delcaration=common_lines
+org.eclipse.jdt.core.formatter.parentheses_positions_in_method_invocation=common_lines
+org.eclipse.jdt.core.formatter.parentheses_positions_in_switch_statement=common_lines
+org.eclipse.jdt.core.formatter.parentheses_positions_in_try_clause=common_lines
org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
org.eclipse.jdt.core.formatter.tabulation.char=space
org.eclipse.jdt.core.formatter.tabulation.size=2
org.eclipse.jdt.core.formatter.use_on_off_tags=true
org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
+org.eclipse.jdt.core.formatter.wrap_before_assignment_operator=false
org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_conditional_operator=true
org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
+org.eclipse.jdt.core.javaFormatter=org.eclipse.jdt.core.defaultJavaFormatter
eclipse.preferences.version=1
editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
formatter_profile=_Jalview
-formatter_settings_version=12
+formatter_settings_version=13
org.eclipse.jdt.ui.ignorelowercasenames=true
org.eclipse.jdt.ui.importorder=jalview;java;javax;org;com;
org.eclipse.jdt.ui.ondemandthreshold=99
public TreeModel(SequenceI[] seqs, AlignmentView odata,
NewickFile treefile)
{
- this(seqs, treefile.getTree(), treefile.HasDistances(),
- treefile.HasBootstrap(), treefile.HasRootDistance());
+ this(seqs, treefile.getTree(), treefile.hasDistances(),
+ treefile.hasBootstrap(), treefile.hasRootDistance());
seqData = odata;
associateLeavesToSequences(seqs);
{
// Set default view, paying lip service to any overriding tree view
// parameter settings
- boolean showDist = newtree.HasDistances()
+ boolean showDist = newtree.hasDistances()
&& av.applet.getDefaultParameter("showTreeDistances",
- newtree.HasDistances());
- boolean showBoots = newtree.HasBootstrap()
+ newtree.hasDistances());
+ boolean showBoots = newtree.hasBootstrap()
&& av.applet.getDefaultParameter("showTreeBootstraps",
- newtree.HasBootstrap());
+ newtree.hasBootstrap());
distanceMenu.setState(showDist);
bootstrapMenu.setState(showBoots);
treeCanvas.setShowBootstrap(showBoots);
import jalview.datamodel.SequenceFeature;
import jalview.datamodel.SequenceI;
import jalview.datamodel.SequenceNode;
+import jalview.ext.archaeopteryx.Testo;
import jalview.io.JalviewFileChooser;
import jalview.io.JalviewFileView;
import jalview.io.NewickFile;
import java.awt.event.ActionListener;
import java.awt.image.BufferedImage;
import java.beans.PropertyChangeEvent;
+import java.io.File;
import java.io.FileOutputStream;
+import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
}
});
+
TreeLoader tl = new TreeLoader(newTree, inputData);
tl.start();
{
// Must be outside run(), as Jalview2XML tries to
// update distance/bootstrap visibility at the same time
- showBootstrap(newickFile.HasBootstrap());
- showDistances(newickFile.HasDistances());
+ showBootstrap(newickFile.hasBootstrap());
+ showDistances(newickFile.hasDistances());
+
}
+
}
@Override
tree.findHeight(tree.getTopNode());
treeCanvas.setTree(tree);
treeCanvas.repaint();
+
+ Testo test = new Testo();
+ NewickFile newickTree = test.treeToNewick(tree);
+ File newickAsFile = test.newickToArchaeopteryx(newickTree);
+ try
+ {
+ String[] archaeCommandlineArgs = {
+ "-open", newickAsFile.getCanonicalPath() };
+ test.startArchaeopteryx(archaeCommandlineArgs);
+ } catch (IOException e)
+ {
+ e.printStackTrace();
+ }
av.setCurrentTree(tree);
if (av.getSortByTree())
{
if (treeCanvas.applyToAllViews)
{
- final ArrayList<CommandI> commands = new ArrayList<CommandI>();
+ final ArrayList<CommandI> commands = new ArrayList<>();
for (AlignmentPanel ap : PaintRefresher
.getAssociatedPanels(av.getSequenceSetId()))
{
{
SequenceNode root;
- private boolean HasBootstrap = false;
+ private boolean hasBootstrap = false;
- private boolean HasDistances = false;
+ private boolean hasDistances = false;
- private boolean RootHasDistance = false;
+ private boolean rootHasDistance = false;
// File IO Flags
- boolean ReplaceUnderscores = false;
+ boolean replaceUnderscores = false;
boolean printRootInfo = true;
*/
public NewickFile(SequenceNode newtree, boolean bootstrap)
{
- HasBootstrap = bootstrap;
+ hasBootstrap = bootstrap;
root = newtree;
}
boolean distances)
{
root = newtree;
- HasBootstrap = bootstrap;
- HasDistances = distances;
+ hasBootstrap = bootstrap;
+ hasDistances = distances;
}
/**
boolean distances, boolean rootdistance)
{
root = newtree;
- HasBootstrap = bootstrap;
- HasDistances = distances;
- RootHasDistance = rootdistance;
+ hasBootstrap = bootstrap;
+ hasDistances = distances;
+ rootHasDistance = rootdistance;
}
/**
// @tree annotations
// These are set automatically by the reader
- public boolean HasBootstrap()
+ public boolean hasBootstrap()
{
- return HasBootstrap;
+ return hasBootstrap;
}
/**
*
* @return DOCUMENT ME!
*/
- public boolean HasDistances()
+ public boolean hasDistances()
{
- return HasDistances;
+ return hasDistances;
}
- public boolean HasRootDistance()
+ public boolean hasRootDistance()
{
- return RootHasDistance;
+ return rootHasDistance;
}
/**
{
if (nodename == null)
{
- if (ReplaceUnderscores)
+ if (replaceUnderscores)
{
nodename = uqnodename.stringMatched(1).replace('_', ' ');
}
{
bootstrap = (new Integer(nbootstrap.stringMatched(1)))
.intValue();
- HasBootstrap = true;
+ hasBootstrap = true;
} catch (Exception e)
{
Error = ErrorStringrange(Error, "Can't parse bootstrap value",
try
{
distance = (new Float(ndist.stringMatched(1))).floatValue();
- HasDistances = true;
+ hasDistances = true;
nodehasdistance = true;
} catch (Exception e)
{
// Write node info here
c.setName(nodename);
// Trees without distances still need a render distance
- c.dist = (HasDistances) ? distance : DefDistance;
+ c.dist = (hasDistances) ? distance : DefDistance;
// be consistent for internal bootstrap defaults too
- c.setBootstrap((HasBootstrap) ? bootstrap : DefBootstrap);
+ c.setBootstrap((hasBootstrap) ? bootstrap : DefBootstrap);
if (c == realroot)
{
- RootHasDistance = nodehasdistance; // JBPNote This is really
+ rootHasDistance = nodehasdistance; // JBPNote This is really
// UGLY!!! Ensure root node gets
// its given distance
}
{
// Find a place to put the leaf
SequenceNode newnode = new SequenceNode(null, c, nodename,
- (HasDistances) ? distance : DefDistance,
- (HasBootstrap) ? bootstrap : DefBootstrap, false);
+ (hasDistances) ? distance : DefDistance,
+ (hasBootstrap) ? bootstrap : DefBootstrap, false);
parseNHXNodeProps(c, commentString2);
commentString2 = null;
// Insert a dummy node for polytomy
// dummy nodes have distances
SequenceNode newdummy = new SequenceNode(null, c, null,
- (HasDistances ? 0 : DefDistance), 0, true);
+ (hasDistances ? 0 : DefDistance), 0, true);
newdummy.SetChildren(c.left(), newnode);
c.setLeft(newdummy);
}
// (root.right()!=null && root.isDummy())
root = (SequenceNode) root.right().detach(); // remove the imaginary root.
- if (!RootHasDistance)
+ if (!rootHasDistance)
{
- root.dist = (HasDistances) ? 0 : DefDistance;
+ root.dist = (hasDistances) ? 0 : DefDistance;
}
}
v = iv.intValue(); // jalview only does integer bootstraps
// currently
c.setBootstrap(v);
- HasBootstrap = true;
+ hasBootstrap = true;
}
// more codes here.
} catch (Exception e)
{
synchronized (this)
{
- boolean boots = this.HasBootstrap;
- this.HasBootstrap = withbootstraps;
+ boolean boots = this.hasBootstrap;
+ this.hasBootstrap = withbootstraps;
String rv = print();
- this.HasBootstrap = boots;
+ this.hasBootstrap = boots;
return rv;
}
{
synchronized (this)
{
- boolean dists = this.HasDistances;
- this.HasDistances = withdists;
+ boolean dists = this.hasDistances;
+ this.hasDistances = withdists;
String rv = print(withbootstraps);
- this.HasDistances = dists;
+ this.hasDistances = dists;
return rv;
}
private String printNodeField(SequenceNode c)
{
return ((c.getName() == null) ? "" : nodeName(c.getName()))
- + ((HasBootstrap) ? ((c.getBootstrap() > -1)
+ + ((hasBootstrap) ? ((c.getBootstrap() > -1)
? ((c.getName() != null ? " " : "") + c.getBootstrap())
: "") : "")
- + ((HasDistances) ? (":" + c.dist) : "");
+ + ((hasDistances) ? (":" + c.dist) : "");
}
/**
{
return (printRootInfo)
? (((root.getName() == null) ? "" : nodeName(root.getName()))
- + ((HasBootstrap)
+ + ((hasBootstrap)
? ((root.getBootstrap() > -1)
? ((root.getName() != null ? " " : "")
+ +root.getBootstrap())
: "")
: "")
- + ((RootHasDistance) ? (":" + root.dist) : ""))
+ + ((rootHasDistance) ? (":" + root.dist) : ""))
: "";
}
SequenceNode tree = nf.getTree();
AssertJUnit.assertTrue(stage + "Null Tree", tree != null);
stage = "Creating newick file from testTree " + treename;
- String gentree = new NewickFile(tree).print(nf.HasBootstrap(),
- nf.HasDistances());
+ String gentree = new NewickFile(tree).print(nf.hasBootstrap(),
+ nf.hasDistances());
AssertJUnit.assertTrue(stage + "Empty string generated",
gentree != null && gentree.trim().length() > 0);
stage = "Parsing regenerated testTree " + treename;