diff --git a/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/MuonAnalysis.h b/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/MuonAnalysis.h index a79eb7b86da0..845cf998250f 100644 --- a/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/MuonAnalysis.h +++ b/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/MuonAnalysis.h @@ -321,9 +321,6 @@ private slots: /// Deletes a workspace _or_ a workspace group with the given name, if one exists void deleteWorkspaceIfExists(const std::string& wsName); - /// Check if grouping in table is consistent with data file - std::string isGroupingAndDataConsistent(); - ///Return true if data are loaded bool areDataLoaded(); diff --git a/Code/Mantid/MantidQt/CustomInterfaces/src/MuonAnalysis.cpp b/Code/Mantid/MantidQt/CustomInterfaces/src/MuonAnalysis.cpp index c15363871378..e0b59179c068 100644 --- a/Code/Mantid/MantidQt/CustomInterfaces/src/MuonAnalysis.cpp +++ b/Code/Mantid/MantidQt/CustomInterfaces/src/MuonAnalysis.cpp @@ -2283,7 +2283,6 @@ double MuonAnalysis::plotFromTime() return returnValue; } - /** * According to Plot Options what time should we plot to in ms * @return time to plot to in ms @@ -2303,80 +2302,6 @@ double MuonAnalysis::plotToTime() return retVal; } - -/** -* Check if grouping in table is consistent with data file -* -* @return empty string if OK otherwise a complaint -*/ -std::string MuonAnalysis::isGroupingAndDataConsistent() -{ - std::string complaint = "Grouping inconsistent with data file. Plotting disabled.\n"; - - // should probably farm the getting of matrix workspace out into separate method or store - // as attribute assigned in inputFileChanged - Workspace_sptr workspace_ptr = AnalysisDataService::Instance().retrieve(m_workspace_name); - WorkspaceGroup_sptr wsPeriods = boost::dynamic_pointer_cast(workspace_ptr); - MatrixWorkspace_sptr matrix_workspace; - if (wsPeriods) - { - Workspace_sptr workspace_ptr1 = AnalysisDataService::Instance().retrieve(m_workspace_name + "_1"); - matrix_workspace = boost::dynamic_pointer_cast(workspace_ptr1); - } - else - { - matrix_workspace = boost::dynamic_pointer_cast(workspace_ptr); - } - - int nDet = static_cast(matrix_workspace->getNumberHistograms()); - - complaint += "Number of spectra in data = " + boost::lexical_cast(nDet) + ". "; - - int numG = numGroups(); - bool returnComplaint = false; - for (int iG = 0; iG < numG; iG++) - { - typedef Poco::StringTokenizer tokenizer; - tokenizer values(m_uiForm.groupTable->item(m_groupToRow[iG],1)->text().toStdString(), ",", tokenizer::TOK_TRIM); - - for (int i = 0; i < static_cast(values.count()); i++) - { - std::size_t found= values[i].find("-"); - if (found!=std::string::npos) - { - tokenizer aPart(values[i], "-", tokenizer::TOK_TRIM); - - int rightInt; - std::stringstream rightRead(aPart[1]); - rightRead >> rightInt; - - if ( rightInt > nDet ) - { - complaint += " Group-table row " + boost::lexical_cast(m_groupToRow[iG]+1) + " refers to spectrum " - + boost::lexical_cast(rightInt) + "."; - returnComplaint = true; - break; - } - } - else - { - if ( (boost::lexical_cast(values[i].c_str()) > nDet) || (boost::lexical_cast(values[i].c_str()) < 1) ) - { - complaint += " Group-table row " + boost::lexical_cast(m_groupToRow[iG]+1) + " refers to spectrum " - + values[i] + "."; - returnComplaint = true; - break; - } - } - } - } - if ( returnComplaint ) - return complaint; - else - return std::string(""); -} - - /** * Load auto saved values */