Esempio n. 1
0
//--------------------------------------------------------------
// set the range
void SpeedUI::setRange(
  double range)
{
  if (m_range == range)
    return;

  m_range = range;
  formatRange();
}
Esempio n. 2
0
//--------------------------------------------------------------
// set the units
void SpeedUI::setUnits(
  int units)
{
  if (m_units == units)
    return;

  m_units = units;

  formatSpeed();
  formatRange();
}
Esempio n. 3
0
void ParameterFile::initialize(const TreeAln& traln, const ParameterList& parameters,  nat someId, bool isDryRun )  
{        
  rejectIfExists(fullFileName); 

  if(isDryRun)
    return; 

  auto&& fh =  std::ofstream{fullFileName,std::fstream::out}; 

  fh << "[ID: " << someId << "]\n"; 

  fh << "Gen";
  fh << "\tLnPr"; 
  fh << "\tLnL" ; 

  auto blParams = std::vector<AbstractParameter*> {}; 
  for(auto &param : parameters)
    if(param->getCategory() == Category::BRANCH_LENGTHS
       && param->getPrior()->needsIntegration() )
      blParams.push_back(param); 

  for(auto &param : blParams)    
    {
      fh << "\tTL{" ; 
      formatRange(fh, param->getPartitions()); 
      fh << "}"; 
    }

  for(auto &p : parameters)
    {
      if(p->isPrintToParamFile())
	{
	  fh << "\t" ; 
	  p->printAllComponentNames(fh, traln); 
	}
    }

  fh << std::endl; 

  fh.close(); 
}