Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
3 changes: 0 additions & 3 deletions src/dr/app/beast/development_parsers.properties
Original file line number Diff line number Diff line change
Expand Up @@ -147,9 +147,6 @@ dr.inference.operators.factorAnalysis.LoadingsRotationOperator
dr.inference.model.SVDStatistic
dr.inferencexml.operators.factorAnalysis.IntegratedFactorsParser

# SEQUENCE SIMULATOR
dr.app.seqgen.RecomboGen

# POPULATION MODELS
dr.evomodel.epidemiology.LogisticGrowthN0ModelParser
dr.evomodelxml.coalescent.demographicmodel.ExponentialConstantModelParser
Expand Down
105 changes: 29 additions & 76 deletions src/dr/app/beast/release_parsers.properties
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,6 @@ dr.evoxml.GeneralDataTypeParser
dr.evoxml.CompositeDataTypeParser
dr.evoxml.DateParser
dr.evoxml.LocationParser
dr.evoxml.OldHiddenNucleotideParser
dr.evoxml.MicrosatelliteParser
dr.evoxml.MicrosatellitePatternParser
dr.evoxml.MicrosatelliteSimulatorParser
dr.evoxml.KStateDataTypeParser
dr.evoxml.MutationDeathTypeParser
dr.evoxml.MetagenomeDataParser
Expand Down Expand Up @@ -286,7 +282,6 @@ dr.evoxml.MultiLociDistanceParser

# TREE MODELS
dr.evomodelxml.tree.TreeModelParser
dr.evomodelxml.tree.MicrosatelliteSamplerTreeModelParser
dr.evomodelxml.tree.TipHeightLikelihoodParser
dr.evomodelxml.tree.TreeMetricStatisticParser
dr.evomodelxml.tree.TreeLengthStatisticParser
Expand Down Expand Up @@ -327,14 +322,8 @@ dr.evomodelxml.operators.GibbsPruneAndRegraftParser
dr.evomodelxml.operators.RateExchangeOperatorParser
dr.evomodelxml.operators.TreeBitMoveOperatorParser
dr.evomodelxml.operators.TreeBitRandomWalkOperatorParser
dr.evomodelxml.operators.TreeNodeSlideParser
dr.evomodel.continuous.GibbsIndependentCoalescentOperator
dr.evomodel.continuous.CoalescentTreeRejectionSampler
dr.evomodelxml.operators.MicrosatelliteUpDownOperatorParser
dr.evomodelxml.operators.MicrosatelliteBitFlipOperatorParser
dr.evomodelxml.operators.MicrosatelliteModelSelectOperatorParser
dr.evomodelxml.operators.MicrosatelliteFullAncestryImportanceSamplingOperatorParser
dr.evomodelxml.operators.MicrosatelliteSingleAncestralStateGibbsOperatorParser
dr.evomodelxml.operators.RandomWalkIntegerNodeHeightWeightedOperatorParser
dr.evomodelxml.operators.RandomWalkIntegerSetSizeWeightedOperatorParser

Expand All @@ -350,7 +339,7 @@ dr.evomodelxml.tree.CTMCScalePriorParser
# RATE OPERATORS
dr.evomodelxml.operators.RateScaleOperatorParser
dr.evomodelxml.operators.RateVarianceScaleOperatorParser
dr.evomodelxml.operators.RateSampleOperatorParser
#dr.evomodelxml.operators.RateSampleOperatorParser

# LIKELIHOODS
dr.inferencexml.model.CompoundLikelihoodParser
Expand Down Expand Up @@ -546,19 +535,16 @@ dr.inferencexml.model.DiagonalMatrixParser
dr.inferencexml.model.CompoundSymmetricMatrixParser
dr.inferencexml.model.CorrelationSymmetricMatrixParser
dr.inferencexml.model.MarkovRandomFieldMatrixParser
dr.inferencexml.distribution.MultivariateOUModelParser
#dr.inferencexml.distribution.MultivariateOUModelParser
dr.inferencexml.model.CachedMatrixInverseParser

dr.oldevomodelxml.substmodel.PositiveDefiniteSubstitutionModelParser
dr.evomodelxml.substmodel.PositiveDefiniteSubstitutionModelParser

# STOCHASTIC VARIABLE SELECTION
dr.evomodel.operators.BitFlipInSubstitutionModelOperator
dr.inference.operators.RateBitExchangeOperator
dr.inferencexml.distribution.CachedDistributionLikelihoodParser

# SEQUENCE SIMULATOR
dr.app.seqgen.SequenceSimulator

# SPECIAL STATISTICS
dr.inference.model.MonotonicStatistic
dr.inference.model.MatrixInverseStatistic
Expand All @@ -580,34 +566,32 @@ dr.inferencexml.model.LikelihoodBenchmarkerParser
dr.inferencexml.distribution.EmpiricalDistributionLikelihoodParser

# ANCESTRAL RECOMBINATION GRAPHS
dr.evomodel.arg.coalescent.ARGCoalescentLikelihood
dr.evomodel.arg.coalescent.ARGUniformPrior
dr.evomodel.arg.likelihood.ARGLikelihood
dr.evomodel.arg.operators.SlidingPatternsOperator
dr.evomodel.arg.branchratemodel.ARGDiscretizedBranchRates
dr.evomodel.arg.ARGModel
dr.evomodel.arg.UniformPartitionLikelihood
dr.evomodel.arg.operators.ARGSubtreeSlideOperator
dr.evomodel.arg.operators.ARGExchangeOperator
dr.evomodel.arg.operators.ObsoleteARGAddRemoveEventOperator
dr.evomodel.arg.operators.ARGPartitioningOperator
dr.evomodel.arg.operators.ObsoleteARGNewEventOperator
dr.evomodel.arg.operators.ARGAddRemoveEventOperator
dr.evomodel.arg.operators.ARGSwapOperator
dr.evomodel.arg.ARGReassortmentNodeCountStatistic
dr.evomodel.arg.ARGTraceAnalysisParser
dr.evomodel.arg.ARGReassortmentTimingStatistic
dr.evomodel.arg.PoissonPartitionLikelihood
dr.evomodel.arg.RecombinationPartitionStatistic
dr.evomodel.arg.ARGTotalLengthStatistic
dr.evomodel.arg.ARGDistinctTreeCountStatistic
dr.evomodel.arg.HierarchicalPartitionLikelihood
dr.evomodel.arg.ARGRelaxedClock
dr.evomodel.arg.ARGRatePrior
dr.evomodel.arg.ARGTreeLogger
dr.evomodel.arg.ARGLogger

dr.evoxml.MicrosatellitePatternStatisticParser
#dr.evomodel.arg.coalescent.ARGCoalescentLikelihood
#dr.evomodel.arg.coalescent.ARGUniformPrior
#dr.evomodel.arg.likelihood.ARGLikelihood
#dr.evomodel.arg.operators.SlidingPatternsOperator
#dr.evomodel.arg.branchratemodel.ARGDiscretizedBranchRates
#dr.evomodel.arg.ARGModel
#dr.evomodel.arg.UniformPartitionLikelihood
#dr.evomodel.arg.operators.ARGSubtreeSlideOperator
#dr.evomodel.arg.operators.ARGExchangeOperator
#dr.evomodel.arg.operators.ObsoleteARGAddRemoveEventOperator
#dr.evomodel.arg.operators.ARGPartitioningOperator
#dr.evomodel.arg.operators.ObsoleteARGNewEventOperator
#dr.evomodel.arg.operators.ARGAddRemoveEventOperator
#dr.evomodel.arg.operators.ARGSwapOperator
#dr.evomodel.arg.ARGReassortmentNodeCountStatistic
#dr.evomodel.arg.ARGTraceAnalysisParser
#dr.evomodel.arg.ARGReassortmentTimingStatistic
#dr.evomodel.arg.PoissonPartitionLikelihood
#dr.evomodel.arg.RecombinationPartitionStatistic
#dr.evomodel.arg.ARGTotalLengthStatistic
#dr.evomodel.arg.ARGDistinctTreeCountStatistic
#dr.evomodel.arg.HierarchicalPartitionLikelihood
#dr.evomodel.arg.ARGRelaxedClock
#dr.evomodel.arg.ARGRatePrior
#dr.evomodel.arg.ARGTreeLogger
#dr.evomodel.arg.ARGLogger

# N & S counting
dr.evomodel.trace.DnDsPerSiteAnalysis
Expand Down Expand Up @@ -728,34 +712,3 @@ dr.evomodel.antigenic.NPAntigenicLikelihood
# NEW ANTIGENIC EVOLUTION/EVOLUTIONARY CARTOGRAPHY
dr.evomodelxml.antigenic.AntigenicLikelihoodParser
dr.evomodelxml.antigenic.AntigenicLikelihoodGradientParser

## AlloppNet by Graham Jones
# ALLOPOLYPLOID NETWORKS
dr.evomodel.alloppnet.parsers.AlloppMSCoalescentParser
dr.evomodel.alloppnet.parsers.AlloppNetworkPriorModelParser
dr.evomodel.alloppnet.parsers.AlloppNetworkPriorParser
dr.evomodel.alloppnet.parsers.AlloppSpeciesBindingsApSpInfoParser
dr.evomodel.alloppnet.parsers.AlloppSpeciesBindingsIndividualParser
dr.evomodel.alloppnet.parsers.AlloppSpeciesBindingsParser
dr.evomodel.alloppnet.parsers.AlloppSpeciesNetworkModelParser
dr.evomodel.alloppnet.parsers.AlloppNumHybsStatisticParser

# MULTIPLY LABELLED TREES
dr.evomodel.alloppnet.parsers.MulMSCoalescentParser
dr.evomodel.alloppnet.parsers.MulSpeciesBindingsParser
dr.evomodel.alloppnet.parsers.MulSpeciesTreeModelParser
dr.evomodel.alloppnet.parsers.MulSpeciesTreePriorParser

# OPERATORS
dr.evomodel.alloppnet.parsers.AlloppNetworkNodeSlideParser
dr.evomodel.alloppnet.parsers.AlloppSequenceReassignmentParser
dr.evomodel.alloppnet.parsers.AlloppMoveLegsParser
dr.evomodel.alloppnet.parsers.AlloppChangeNumHybridizationsParser
dr.evomodel.alloppnet.parsers.AlloppHybPopSizesScaleParser
dr.evomodel.alloppnet.parsers.MulTreeNodeSlideParser
dr.evomodel.alloppnet.parsers.MulTreeSequenceReassignmentParser

## DISSECT by Graham Jones
# SPECIES DELIMITATION
dr.evomodel.alloppnet.parsers.BirthDeathCollapseModelParser
dr.evomodel.alloppnet.parsers.BirthDeathCollapseNClustersStatisticParser
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,8 @@
import dr.evomodel.tree.DefaultTreeModel;
import dr.evomodel.tree.TreeModel;
import dr.evomodelxml.tree.TreeLoggerParser;
import dr.evomodelxml.treelikelihood.AncestralStateTreeLikelihoodParser;
import dr.evomodelxml.treelikelihood.MarkovJumpsTreeLikelihoodParser;
import dr.oldevomodelxml.treelikelihood.AncestralStateTreeLikelihoodParser;
import dr.util.Attribute;

import java.util.ArrayList;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,11 @@
package dr.app.beauti.components.discrete;

import dr.evomodel.tree.DefaultTreeModel;
import dr.evomodelxml.substmodel.ComplexSubstitutionModelParser;
import dr.evomodelxml.substmodel.FrequencyModelParser;
import dr.evomodelxml.substmodel.GeneralSubstitutionModelParser;
import dr.evomodelxml.substmodel.GlmSubstitutionModelParser;
import dr.evomodelxml.treelikelihood.AncestralStateTreeLikelihoodParser;
import dr.evomodelxml.treelikelihood.MarkovJumpsTreeLikelihoodParser;
import dr.app.beauti.components.ancestralstates.AncestralStatesComponentOptions;
import dr.app.beauti.generator.BaseComponentGenerator;
Expand All @@ -42,14 +46,6 @@
import dr.inference.operators.MultivariateNormalOperator;
import dr.inferencexml.distribution.BinomialLikelihoodParser;
import dr.inferencexml.distribution.GeneralizedLinearModelParser;
import dr.oldevomodel.sitemodel.SiteModel;
import dr.oldevomodel.substmodel.AbstractSubstitutionModel;
import dr.oldevomodelxml.sitemodel.GammaSiteModelParser;
import dr.oldevomodelxml.substmodel.ComplexSubstitutionModelParser;
import dr.oldevomodelxml.substmodel.FrequencyModelParser;
import dr.oldevomodelxml.substmodel.GeneralSubstitutionModelParser;
import dr.oldevomodelxml.treelikelihood.AncestralStateTreeLikelihoodParser;
import dr.oldevomodelxml.treelikelihood.TreeLikelihoodParser;
import dr.evoxml.AttributePatternsParser;
import dr.evoxml.GeneralDataTypeParser;
import dr.evoxml.TaxaParser;
Expand All @@ -63,7 +59,12 @@

import java.util.Set;

import static dr.app.phylogeography.tools.DiscreteRatePriorGenerator.MODEL;
import static dr.evomodelxml.siteratemodel.SiteModelParser.SITE_MODEL;
import static dr.evomodelxml.siteratemodel.SiteModelParser.SUBSTITUTION_MODEL;
import static dr.evomodelxml.substmodel.ComplexSubstitutionModelParser.ROOT_FREQUENCIES;
import static dr.evomodelxml.treelikelihood.AncestralStateTreeLikelihoodParser.RECONSTRUCTING_TREE_LIKELIHOOD;
import static dr.evomodelxml.treelikelihood.BeagleTreeLikelihoodParser.TREE_LIKELIHOOD;

/**
* @author Andrew Rambaut
Expand Down Expand Up @@ -274,7 +275,7 @@ private void writeDiscreteTraitsSubstitutionModel(PartitionSubstitutionModel mod
writer.writeComment("symmetric CTMC model for discrete state reconstructions");

writer.writeOpenTag(GeneralSubstitutionModelParser.GENERAL_SUBSTITUTION_MODEL, new Attribute[]{
new Attribute.Default<String>(XMLParser.ID, prefix + AbstractSubstitutionModel.MODEL)});
new Attribute.Default<String>(XMLParser.ID, prefix + MODEL)});

writer.writeIDref(GeneralDataTypeParser.GENERAL_DATA_TYPE, prefix + "dataType");

Expand All @@ -292,7 +293,7 @@ private void writeDiscreteTraitsSubstitutionModel(PartitionSubstitutionModel mod
writer.writeComment("asymmetric CTMC model for discrete state reconstructions");

writer.writeOpenTag(GeneralSubstitutionModelParser.GENERAL_SUBSTITUTION_MODEL, new Attribute[]{
new Attribute.Default<String>(XMLParser.ID, prefix + AbstractSubstitutionModel.MODEL),
new Attribute.Default<String>(XMLParser.ID, prefix + MODEL),
new Attribute.Default<Boolean>(ComplexSubstitutionModelParser.RANDOMIZE, false)});

writer.writeIDref(GeneralDataTypeParser.GENERAL_DATA_TYPE, prefix + "dataType");
Expand All @@ -311,7 +312,7 @@ private void writeDiscreteTraitsSubstitutionModel(PartitionSubstitutionModel mod
writer.writeComment("GLM substitution model");

writer.writeOpenTag(GlmSubstitutionModelParser.GLM_SUBSTITUTION_MODEL, new Attribute[] {
new Attribute.Default<String>(XMLParser.ID, prefix + AbstractSubstitutionModel.MODEL)
new Attribute.Default<String>(XMLParser.ID, prefix + MODEL)
});

writer.writeIDref(GeneralDataTypeParser.GENERAL_DATA_TYPE, prefix + "dataType");
Expand Down Expand Up @@ -398,9 +399,9 @@ private void writeDiscreteTraitsSubstitutionModelReferences(XMLWriter writer) {
for (PartitionSubstitutionModel model : options.getPartitionSubstitutionModels(GeneralDataType.INSTANCE)) {
if (model.getDiscreteSubstType() == DiscreteSubstModelType.GLM_SUBST) {
// not strictly necessary but makes the XML consistent
writer.writeIDref(GlmSubstitutionModelParser.GLM_SUBSTITUTION_MODEL, model.getName() + "." + AbstractSubstitutionModel.MODEL);
writer.writeIDref(GlmSubstitutionModelParser.GLM_SUBSTITUTION_MODEL, model.getName() + "." + MODEL);
} else {
writer.writeIDref(GeneralSubstitutionModelParser.GENERAL_SUBSTITUTION_MODEL, model.getName() + "." + AbstractSubstitutionModel.MODEL);
writer.writeIDref(GeneralSubstitutionModelParser.GENERAL_SUBSTITUTION_MODEL, model.getName() + "." + MODEL);
}
}
}
Expand Down Expand Up @@ -434,19 +435,19 @@ private void writeDiscreteFrequencyModel(String prefix, String dataTypePrefix, i

private void writeDiscreteTraitsSiteModel(PartitionSubstitutionModel model, XMLWriter writer) {
String prefix = model.getName() + ".";
writer.writeOpenTag(SiteModel.SITE_MODEL, new Attribute[]{
new Attribute.Default<String>(XMLParser.ID, prefix + SiteModel.SITE_MODEL)});
writer.writeOpenTag(SITE_MODEL, new Attribute[]{
new Attribute.Default<String>(XMLParser.ID, prefix + SITE_MODEL)});

writer.writeOpenTag(GammaSiteModelParser.SUBSTITUTION_MODEL);
writer.writeOpenTag(SUBSTITUTION_MODEL);
if (model.getDiscreteSubstType() == DiscreteSubstModelType.GLM_SUBST) {
// not strictly necessary but makes the XML consistent
writer.writeIDref(GlmSubstitutionModelParser.GLM_SUBSTITUTION_MODEL, prefix + AbstractSubstitutionModel.MODEL);
writer.writeIDref(GlmSubstitutionModelParser.GLM_SUBSTITUTION_MODEL, prefix + MODEL);
} else {
writer.writeIDref(GeneralSubstitutionModelParser.GENERAL_SUBSTITUTION_MODEL, prefix + AbstractSubstitutionModel.MODEL);
writer.writeIDref(GeneralSubstitutionModelParser.GENERAL_SUBSTITUTION_MODEL, prefix + MODEL);
}
writer.writeCloseTag(GammaSiteModelParser.SUBSTITUTION_MODEL);
writer.writeCloseTag(SUBSTITUTION_MODEL);

writer.writeCloseTag(SiteModel.SITE_MODEL);
writer.writeCloseTag(SITE_MODEL);
}

private void writeRatesAndIndicators(PartitionSubstitutionModel model, int dimension, Integer relativeTo, XMLWriter writer) {
Expand Down Expand Up @@ -518,15 +519,15 @@ public void writeTreeLikelihood(AbstractPartitionData partition, XMLWriter write
PartitionClockModel clockModel = partition.getPartitionClockModel();

AncestralStatesComponentOptions ancestralStatesOptions = (AncestralStatesComponentOptions)options.getComponentOptions(AncestralStatesComponentOptions.class);
String treeLikelihoodTag = TreeLikelihoodParser.ANCESTRAL_TREE_LIKELIHOOD;
String treeLikelihoodTag = RECONSTRUCTING_TREE_LIKELIHOOD;
if (ancestralStatesOptions.isCountingStates(partition)) {
treeLikelihoodTag = MarkovJumpsTreeLikelihoodParser.MARKOV_JUMP_TREE_LIKELIHOOD;
}

boolean saveCompleteHistory = ancestralStatesOptions.isCompleteHistoryLogging(partition);

writer.writeOpenTag(treeLikelihoodTag, new Attribute[]{
new Attribute.Default<String>(XMLParser.ID, prefix + TreeLikelihoodParser.TREE_LIKELIHOOD),
new Attribute.Default<String>(XMLParser.ID, prefix + TREE_LIKELIHOOD),
new Attribute.Default<String>(AncestralStateTreeLikelihoodParser.RECONSTRUCTION_TAG_NAME, prefix + AncestralStateTreeLikelihoodParser.RECONSTRUCTION_TAG),
new Attribute.Default<Boolean>(MarkovJumpsTreeLikelihoodParser.USE_UNIFORMIZATION, true),
new Attribute.Default<String>(MarkovJumpsTreeLikelihoodParser.SAVE_HISTORY, saveCompleteHistory ? "true" : "false"),
Expand All @@ -535,16 +536,16 @@ public void writeTreeLikelihood(AbstractPartitionData partition, XMLWriter write

writer.writeIDref(AttributePatternsParser.ATTRIBUTE_PATTERNS, prefix + "pattern");
writer.writeIDref(DefaultTreeModel.TREE_MODEL, treeModel.getPrefix() + DefaultTreeModel.TREE_MODEL);
writer.writeIDref(SiteModel.SITE_MODEL, substModel.getName() + "." + SiteModel.SITE_MODEL);
writer.writeIDref(SITE_MODEL, substModel.getName() + "." + SITE_MODEL);

if (partition.getPartitionSubstitutionModel().getDiscreteSubstType() == DiscreteSubstModelType.GLM_SUBST) {
// not strictly necessary but makes the XML consistent
writer.writeIDref(GlmSubstitutionModelParser.GLM_SUBSTITUTION_MODEL, prefix + AbstractSubstitutionModel.MODEL);
writer.writeIDref(GlmSubstitutionModelParser.GLM_SUBSTITUTION_MODEL, prefix + MODEL);
} else {
writer.writeIDref(GeneralSubstitutionModelParser.GENERAL_SUBSTITUTION_MODEL, prefix + AbstractSubstitutionModel.MODEL);
writer.writeIDref(GeneralSubstitutionModelParser.GENERAL_SUBSTITUTION_MODEL, prefix + MODEL);
}

writer.writeIDref(GeneralSubstitutionModelParser.GENERAL_SUBSTITUTION_MODEL, substModel.getName() + "." + AbstractSubstitutionModel.MODEL);
writer.writeIDref(GeneralSubstitutionModelParser.GENERAL_SUBSTITUTION_MODEL, substModel.getName() + "." + MODEL);

ClockModelGenerator.writeBranchRatesModelRef(clockModel, writer);

Expand All @@ -563,7 +564,7 @@ private void writeTreeLikelihoodReferences(XMLWriter writer) {
for (AbstractPartitionData partition : options.dataPartitions) {
if (partition.getTraits() != null) {
AncestralStatesComponentOptions ancestralStatesOptions = (AncestralStatesComponentOptions)options.getComponentOptions(AncestralStatesComponentOptions.class);
String treeLikelihoodTag = TreeLikelihoodParser.ANCESTRAL_TREE_LIKELIHOOD;
String treeLikelihoodTag = RECONSTRUCTING_TREE_LIKELIHOOD;
if (ancestralStatesOptions.isCountingStates(partition)) {
treeLikelihoodTag = MarkovJumpsTreeLikelihoodParser.MARKOV_JUMP_TREE_LIKELIHOOD;
}
Expand All @@ -572,7 +573,7 @@ private void writeTreeLikelihoodReferences(XMLWriter writer) {
String prefix = partition.getName() + ".";
if (trait.getTraitType() == TraitData.TraitType.DISCRETE) {
writer.writeIDref(treeLikelihoodTag,
prefix + TreeLikelihoodParser.TREE_LIKELIHOOD);
prefix + TREE_LIKELIHOOD);
}
}
}
Expand Down
Loading
Loading