Newer
Older
const std::string name = m_instName + "_cal";
AnalysisDataService::Instance().addOrReplace(name, m_calibrationWS);
this->setPropertyValue("CalibrationWorkspace", name);
}
if (loadMask) {
m_maskWS = alg->getProperty("OutputMaskWorkspace");
const std::string name = m_instName + "_mask";
AnalysisDataService::Instance().addOrReplace(name, m_maskWS);
this->setPropertyValue("MaskWorkspace", name);
}
//----------------------------------------------------------------------------------------------
/** Perform SortEvents on the output workspaces
* but only if they are EventWorkspaces.
*
* @param ws :: any Workspace. Does nothing if not EventWorkspace.
*/
void AlignAndFocusPowder::doSortEvents(Mantid::API::Workspace_sptr ws) {
EventWorkspace_sptr eventWS = boost::dynamic_pointer_cast<EventWorkspace>(ws);
if (!eventWS)
return;
Algorithm_sptr alg = this->createChildAlgorithm("SortEvents");
alg->setProperty("InputWorkspace", eventWS);
alg->setPropertyValue("SortBy", "X Value");
alg->executeAsChildAlg();
}