Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: CompEvol/beast2
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v2.7.7
Choose a base ref
...
head repository: CompEvol/beast2
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: master
Choose a head ref
  • 17 commits
  • 14 files changed
  • 3 contributors

Commits on Jun 27, 2024

  1. deal with spaces in quoted attribute values #30

    rbouckaert committed Jun 27, 2024
    Copy the full SHA
    8482048 View commit details

Commits on Jul 19, 2024

  1. improve error message for XML where the spec attribute is missing #28

    rbouckaert committed Jul 19, 2024
    Copy the full SHA
    25df72b View commit details

Commits on Aug 5, 2024

  1. update parameter dimension on -resume #fixes 1159

    jordandouglas committed Aug 5, 2024
    Copy the full SHA
    3916ce5 View commit details

Commits on Aug 30, 2024

  1. Adds CL packagemanager option to add repositories. Closes #1163

    tgvaughan committed Aug 30, 2024
    Copy the full SHA
    16afbfa View commit details

Commits on Sep 1, 2024

  1. Merge pull request #1164 from tgvaughan/packagemanager-patch

    Adds CL packagemanager option to add repositories. Closes #1163
    rbouckaert authored Sep 1, 2024

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature.
    Copy the full SHA
    3dbc14a View commit details

Commits on Sep 9, 2024

  1. facilitate beast "-validate" option CompEvol/BeastFX#86

    rbouckaert committed Sep 9, 2024
    Copy the full SHA
    fe85402 View commit details

Commits on Sep 16, 2024

  1. set ids of trees parsed from NEXUS file. fixes CompEvol/BeastFX#87

    rbouckaert committed Sep 16, 2024
    Copy the full SHA
    c520aaf View commit details

Commits on Sep 23, 2024

  1. fix indexing error in beagle tree likellihood fixes #1168

    jordandouglas committed Sep 23, 2024
    Copy the full SHA
    e6fd752 View commit details

Commits on Sep 24, 2024

  1. correction to #1168

    jordandouglas committed Sep 24, 2024
    Copy the full SHA
    edc84fe View commit details

Commits on Sep 29, 2024

  1. towards renaming scaleFactor to windowSize in BactrianRandomWalkOpera…

    …tor #1169
    rbouckaert committed Sep 29, 2024
    Copy the full SHA
    5eacf16 View commit details

Commits on Oct 31, 2024

  1. add benchmark interface to BeagelTreeLikelihood #1172

    rbouckaert committed Oct 31, 2024
    Copy the full SHA
    65fa457 View commit details
  2. fix compile error #1172

    rbouckaert committed Oct 31, 2024
    Copy the full SHA
    3ed7a39 View commit details

Commits on Jan 5, 2025

  1. make TreeWithMetaDataLogger produce correct nr of commas. fixes #1177

    rbouckaert committed Jan 5, 2025
    Copy the full SHA
    0e97234 View commit details

Commits on Jan 15, 2025

  1. start Alignment refactoring, add TreeTipData #1174

    rbouckaert committed Jan 15, 2025
    Copy the full SHA
    3d6f460 View commit details
  2. robustify tree likelihoods for possibility data is not Alignment #1174

    rbouckaert committed Jan 15, 2025
    Copy the full SHA
    10aaac6 View commit details

Commits on Feb 27, 2025

  1. add public method to GeneralSubstitutionModel fixes #1181

    jordandouglas committed Feb 27, 2025
    Copy the full SHA
    578e9ed View commit details

Commits on Mar 4, 2025

  1. make BactrianOperatorSchedule ignore Uniform operators if parameter i…

    …s not a RealParameter #1183
    rbouckaert committed Mar 4, 2025
    Copy the full SHA
    2745a9f View commit details
12 changes: 9 additions & 3 deletions src/beast/base/evolution/TreeWithMetaDataLogger.java
Original file line number Diff line number Diff line change
@@ -123,11 +123,15 @@ String toNewick(Node node, List<Function> metadataList, BranchRateModel.Base bra
if (someMetaDataNeedsLogging) {
buf2.append("[&");
if (metadataList.size() > 0) {
boolean needsComma = false;
for (Function metadata : metadataList) {
if (metadata instanceof Parameter<?>) {
Parameter<?> p = (Parameter<?>) metadata;
int dim = p.getMinorDimension1();
if (p.getMinorDimension2() > node.getNr()) {
if (needsComma) {
buf2.append(",");
}
buf2.append(((BEASTObject) metadata).getID());
buf2.append('=');
if (dim > 1) {
@@ -152,19 +156,21 @@ String toNewick(Node node, List<Function> metadataList, BranchRateModel.Base bra
buf2.append(metadata.getArrayValue(node.getNr()));
}
}
needsComma = true;
} else {

}
} else {
if (metadata.getDimension() > node.getNr()) {
if (needsComma) {
buf2.append(",");
}
buf2.append(((BEASTObject) metadata).getID());
buf2.append('=');
buf2.append(metadata.getArrayValue(node.getNr()));
needsComma = true;
}
}
if (buf2.length() > 2 && metadataList.indexOf(metadata) < metadataList.size() - 1) {
buf2.append(",");
}
}
if (buf2.length() > 2 && branchRateModel != null) {
buf2.append(",");
102 changes: 2 additions & 100 deletions src/beast/base/evolution/alignment/Alignment.java
Original file line number Diff line number Diff line change
@@ -24,23 +24,19 @@
*/
package beast.base.evolution.alignment;

import java.io.PrintStream;
import java.util.*;

import org.w3c.dom.Node;
import java.util.*;

import beast.base.core.Description;
import beast.base.core.Input;
import beast.base.core.Log;
import beast.base.core.Input.Validate;
import beast.base.evolution.datatype.DataType;
import beast.base.inference.StateNode;
import beast.base.inference.parameter.Map;
import beast.pkgmgmt.BEASTClassLoader;
import beast.pkgmgmt.PackageManager;

@Description("Class representing alignment data")
public class Alignment extends Map<String> {
public class Alignment extends TreeTipData {

@Override
protected Class<?> mapType() {
@@ -105,12 +101,8 @@ static public DataType getDataTypeByName(String name) {
final public Input<List<Sequence>> sequenceInput =
new Input<>("sequence", "sequence and meta data for particular taxon", new ArrayList<>(), Validate.OPTIONAL);

final public Input<TaxonSet> taxonSetInput =
new Input<>("taxa", "An optional taxon-set used only to sort the sequences into the same order as they appear in the taxon-set.", new TaxonSet(), Validate.OPTIONAL);

final public Input<Integer> stateCountInput = new Input<>("statecount", "maximum number of states in all sequences");
final public Input<String> dataTypeInput = new Input<>("dataType", "data type, one of " + types, NUCLEOTIDE, types.keySet().toArray(new String[0]));
final public Input<DataType.Base> userDataTypeInput = new Input<>("userDataType", "non-standard, user specified data type, if specified 'dataType' is ignored");
final public Input<Boolean> stripInvariantSitesInput = new Input<>("strip", "sets weight to zero for sites that are invariant (e.g. all 1, all A or all unkown)", false);
final public Input<String> siteWeightsInput = new Input<>("weights", "comma separated list of weights, one for each site in the sequences. If not specified, each site has weight 1");

@@ -885,96 +877,6 @@ public String getSequenceAsString(String taxon) {
return freqs;
} // calcFrequencies

@Override
public void init(PrintStream out) {
// TODO Auto-generated method stub

}

@Override
public void log(long sample, PrintStream out) {
// TODO Auto-generated method stub

}

@Override
public void close(PrintStream out) {
// TODO Auto-generated method stub

}

@Override
public int getDimension() {
// TODO Auto-generated method stub
return 0;
}

@Override
public double getArrayValue(int dim) {
// TODO Auto-generated method stub
return 0;
}

@Override
public void setEverythingDirty(boolean isDirty) {
// TODO Auto-generated method stub

}

@Override
public StateNode copy() {
// TODO Auto-generated method stub
return null;
}

@Override
public void assignTo(StateNode other) {
// TODO Auto-generated method stub

}

@Override
public void assignFrom(StateNode other) {
// TODO Auto-generated method stub

}

@Override
public void assignFromFragile(StateNode other) {
// TODO Auto-generated method stub

}

@Override
public void fromXML(Node node) {
// TODO Auto-generated method stub

}

@Override
public String toXML() {
// TODO Auto-generated method stub
return null;
}

@Override
public int scale(double scale) {
// TODO Auto-generated method stub
return 0;
}

@Override
protected void store() {
// TODO Auto-generated method stub

}

@Override
public void restore() {
// TODO Auto-generated method stub

}


@Override
public boolean notCloneable() {
98 changes: 98 additions & 0 deletions src/beast/base/evolution/alignment/TreeTipData.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,98 @@
package beast.base.evolution.alignment;


import java.io.PrintStream;

import org.w3c.dom.Node;

import beast.base.core.Description;
import beast.base.core.Input;
import beast.base.core.Input.Validate;
import beast.base.evolution.datatype.DataType;
import beast.base.inference.StateNode;
import beast.base.inference.parameter.Map;

@Description("Generic class for associating data to tips of a tree, e.g. an Alignment.")
public class TreeTipData extends Map<String> {

final public Input<TaxonSet> taxonSetInput =
new Input<>("taxa", "An optional taxon-set used only to sort the sequences into the same order as they appear in the taxon-set.", new TaxonSet(), Validate.OPTIONAL);

final public Input<DataType.Base> userDataTypeInput = new Input<>("userDataType", "non-standard, user specified data type, if specified 'dataType' is ignored");

/** Loggable implementation **/

@Override
public void init(PrintStream out) {
}

@Override
public void log(long sample, PrintStream out) {
}

@Override
public void close(PrintStream out) {
}


/** Function implementation **/

@Override
public int getDimension() {
return 0;
}

@Override
public double getArrayValue(int dim) {
return 0;
}

/** Map implementation **/

@Override
protected Class<?> mapType() {
return String.class;
}


/** StateNode implementation **/

@Override
public void setEverythingDirty(boolean isDirty) {
}

@Override
public StateNode copy() {
return null;
}

@Override
public void assignTo(StateNode other) {
}

@Override
public void assignFrom(StateNode other) {
}

@Override
public void assignFromFragile(StateNode other) {
}

@Override
public void fromXML(Node node) {
}

@Override
public int scale(double scale) {
return 0;
}

@Override
protected void store() {
}

@Override
public void restore() {
}

}
Loading