diff --git a/src/core/automaticfilterparameters.h b/src/core/automaticfilterparameters.h index ee02f445fc8d838746eb22701e08240a5cfdc4e8..6c0e7e8d995946957711cfeb0b3729ebc31c3925 100644 --- a/src/core/automaticfilterparameters.h +++ b/src/core/automaticfilterparameters.h @@ -51,12 +51,12 @@ class AutomaticFilterParameters unsigned int getFilterMinimumPeptidePerMatch() const; bool getFilterCrossSamplePeptideNumber() const; unsigned int getFilterPeptideObservedInLessSamplesThan() const; - + bool useFDR() const; private: - double m_filterFDR = -1; + double m_filterFDR = -1; pappso::pappso_double _filter_minimum_peptide_evalue = 1; pappso::pappso_double _filter_minimum_protein_evalue = 1; unsigned int _filter_minimum_peptide_per_match = 1; diff --git a/src/core/identification_sources/identificationmascotdatfile.cpp b/src/core/identification_sources/identificationmascotdatfile.cpp index 8964d5246d17520ef3d006ead62ff9581080a9b2..a97947fc90a8b9d3b94a741d1f972b1a6d39665c 100644 --- a/src/core/identification_sources/identificationmascotdatfile.cpp +++ b/src/core/identification_sources/identificationmascotdatfile.cpp @@ -36,8 +36,8 @@ IdentificationMascotDatFile::IdentificationMascotDatFile( const QFileInfo &mascot_dat_file) - : IdentificationDataSource(mascot_dat_file.absoluteFilePath()) - , _mascot_dat_file(mascot_dat_file) + : IdentificationDataSource(mascot_dat_file.absoluteFilePath()), + _mascot_dat_file(mascot_dat_file) { _engine = IdentificationEngine::mascot; } diff --git a/src/core/identification_sources/identificationmascotdatfile.h b/src/core/identification_sources/identificationmascotdatfile.h index 88cd8050de4470f4687187145e0b306476a10cdf..12293798d358a061e6c1daaeaa3d8993379c6bb3 100644 --- a/src/core/identification_sources/identificationmascotdatfile.h +++ b/src/core/identification_sources/identificationmascotdatfile.h @@ -51,4 +51,3 @@ class IdentificationMascotDatFile : public IdentificationDataSource private: const QFileInfo _mascot_dat_file; }; - diff --git a/src/core/msrun.cpp b/src/core/msrun.cpp index b0cad14f758684f1aa975777d355a6e06ca68d9b..e7ceae2b607d6d20bbc65bdc325dba4ae9bccec2 100644 --- a/src/core/msrun.cpp +++ b/src/core/msrun.cpp @@ -52,7 +52,7 @@ MsRun::MsRun(const QString &location) : pappso::MsRunId(location) MsRun::MsRun(const MsRun &other) : pappso::MsRunId(other) { - _param_stats = other._param_stats; + _param_stats = other._param_stats; m_centroidOptions = other.m_centroidOptions; } diff --git a/src/core/peptidextp.h b/src/core/peptidextp.h index 6bd6d03db9d4a9d1ea1118f3903305e374e970b2..e485b8e490265439bfa9e416bf4a8315e6180c3d 100644 --- a/src/core/peptidextp.h +++ b/src/core/peptidextp.h @@ -58,7 +58,7 @@ class PeptideXtp : public pappso::Peptide /** @brief human readable string that contains modifications * @param without_label get modifications without existing labels * */ - const QString getModifString(bool without_label =false) const; + const QString getModifString(bool without_label = false) const; /** @brief replace modification in peptide */ diff --git a/src/core/proteinxtp.cpp b/src/core/proteinxtp.cpp index 2be7f7b631b91c6c21def0f5129c58606bf1f620..9282dcd6658cf17ef736c9fd7572fd61bf53a89f 100644 --- a/src/core/proteinxtp.cpp +++ b/src/core/proteinxtp.cpp @@ -185,9 +185,13 @@ class DigestionHandler : public pappso::EnzymeProductInterface public: void setPeptide(std::int8_t sequence_database_id, - const pappso::ProteinSp &protein_sp, bool is_decoy, - const QString &peptide, unsigned int start, bool is_nter, - unsigned int missed_cleavage_number, bool semi_enzyme) override + const pappso::ProteinSp &protein_sp, + bool is_decoy, + const QString &peptide, + unsigned int start, + bool is_nter, + unsigned int missed_cleavage_number, + bool semi_enzyme) override { _peptide_list.append(peptide); }; @@ -237,7 +241,7 @@ ProteinXtp::countTrypticPeptidesForPAI() const void ProteinXtp::parseAccession2dbxref() { - //qDebug() << __FILE__ << " " << __FUNCTION__ << " " << __LINE__; + // qDebug() << __FILE__ << " " << __FUNCTION__ << " " << __LINE__; QStringList access_list = getAccession().split("|"); // if (access.length == 1) QRegExp atg("^[Aa][Tt][MmCc1-5][Gg]\\d{5}\\.?\\d?$"); diff --git a/src/core/qvalue/computeqvalues.cpp b/src/core/qvalue/computeqvalues.cpp index 901ab3021ad3a0339870b027b5c876ef63cff144..f6dab8ad7e9defff62499b766895e99361a8819b 100644 --- a/src/core/qvalue/computeqvalues.cpp +++ b/src/core/qvalue/computeqvalues.cpp @@ -216,13 +216,14 @@ ComputeQvalues::writeDistributionsByEngines(CalcWriterInterface *p_writer) const } // double qvalue = Utils::computeFdr(count_decoy, count_target); // pep->setParam(PeptideEvidenceParam::pappso_qvalue, QVariant(qvalue)); - p_writer->writeCell((int) count_target); + p_writer->writeCell((int)count_target); - p_writer->writeCell((int) count_decoy); + p_writer->writeCell((int)count_decoy); p_writer->writeCell(pep->getEvalue()); - p_writer->writeCell(pep->getParam(PeptideEvidenceParam::pappso_qvalue).toDouble()); + p_writer->writeCell( + pep->getParam(PeptideEvidenceParam::pappso_qvalue).toDouble()); p_writer->writeLine(); } } diff --git a/src/core/qvalue/computeqvalues.h b/src/core/qvalue/computeqvalues.h index 58b6987f47d518f5f971a32e96250431c4e4622b..b98733e38bb74beb33038da9e8f4df05f13bdd08 100644 --- a/src/core/qvalue/computeqvalues.h +++ b/src/core/qvalue/computeqvalues.h @@ -46,8 +46,8 @@ class ComputeQvalues * Destructor */ ~ComputeQvalues(); - - void writeDistributionsByEngines(CalcWriterInterface * p_writer) const; + + void writeDistributionsByEngines(CalcWriterInterface *p_writer) const; private: void computeTandemPeptideEvidenceQvalues( @@ -60,7 +60,6 @@ class ComputeQvalues private: std::set<const PeptideEvidence *> m_falsePeptideEvidenceList; - - std::vector<PeptideEvidence *> m_tandemPeptideEvidenceList; - + + std::vector<PeptideEvidence *> m_tandemPeptideEvidenceList; }; diff --git a/src/core/tandem_run/tandembatchprocess.cpp b/src/core/tandem_run/tandembatchprocess.cpp index 2527eb1d2ffb38835e9e413ab33e6682f225029e..32fdeb9e13fe90cafbe0f5d1a1d60705a6c3d258 100644 --- a/src/core/tandem_run/tandembatchprocess.cpp +++ b/src/core/tandem_run/tandembatchprocess.cpp @@ -375,7 +375,7 @@ TandemBatchProcess::runOne(const QString &mz_file) try { - //QProcess::ExitStatus Status = xt_process->exitStatus(); + // QProcess::ExitStatus Status = xt_process->exitStatus(); const QDateTime dt_begin = QDateTime::currentDateTime(); QSettings settings; diff --git a/src/core/tandem_run/tandembatchprocess.h b/src/core/tandem_run/tandembatchprocess.h index 9596d455d55b02dea783ce706051e724e7913398..f440ada59927928a00486967fa0df731b9d32dfb 100644 --- a/src/core/tandem_run/tandembatchprocess.h +++ b/src/core/tandem_run/tandembatchprocess.h @@ -35,7 +35,8 @@ class TandemBatchProcess { public: - TandemBatchProcess(MainWindow *p_main_window, WorkMonitorInterface *p_monitor, + TandemBatchProcess(MainWindow *p_main_window, + WorkMonitorInterface *p_monitor, const TandemRunBatch &tandem_run_batch); virtual ~TandemBatchProcess(); diff --git a/src/core/tandem_run/tandemcondorprocess.cpp b/src/core/tandem_run/tandemcondorprocess.cpp index 7aab8476ad843945dadfe936169e7942c57a9bcd..0bbf77b73b7f99c3de715bfcb2313bdde70f8cf9 100644 --- a/src/core/tandem_run/tandemcondorprocess.cpp +++ b/src/core/tandem_run/tandemcondorprocess.cpp @@ -262,9 +262,8 @@ TandemCondorProcess::run() << " -t " << settings.value("timstof/tmp_dir_path", QDir::tempPath()) .toString() - << "--tandem" << _tandem_run_batch._tandem_bin_path - << "--centroid" << centroidOption - << endl; + << "--tandem" << _tandem_run_batch._tandem_bin_path + << "--centroid" << centroidOption << endl; } *p_out << "Queue" << endl; } diff --git a/src/core/tandem_run/tandemparameters.cpp b/src/core/tandem_run/tandemparameters.cpp index c15f875316c19d1905d88c61417aaf6dd3bbfd7a..47b972f8adcb1c073e3ac886fa56466cc8a62981 100644 --- a/src/core/tandem_run/tandemparameters.cpp +++ b/src/core/tandem_run/tandemparameters.cpp @@ -266,7 +266,7 @@ TandemParameters::setParamLabelValue(const QString &label, const QString &value) (label == "residue, potential modification mass 3") || (label == "residue, potential modification motif 1") || (label == "residue, potential modification motif 2") || - (label == "residue, potential modification motif 3")|| + (label == "residue, potential modification motif 3") || (label == "spectrum, timstof MS2 centroid parameters")) { // string diff --git a/src/grouping/groupinggroup.cpp b/src/grouping/groupinggroup.cpp index f86ef82f9760c374ed06e7641064a5e44f0a273a..cfcf224ee59c3d41676855090b3e470296d71863 100644 --- a/src/grouping/groupinggroup.cpp +++ b/src/grouping/groupinggroup.cpp @@ -275,7 +275,8 @@ unsigned int GroupingGroup::countProteinInSubgroup(unsigned int subgroup_number) const { return std::count_if( - _protein_match_list.begin(), _protein_match_list.end(), + _protein_match_list.begin(), + _protein_match_list.end(), [subgroup_number](const ProteinMatch *p_protein_match) { if(p_protein_match->getGrpProteinSp().get()->getSubGroupNumber() == subgroup_number) diff --git a/src/grouping/ptm/ptmgroupingexperiment.cpp b/src/grouping/ptm/ptmgroupingexperiment.cpp index 903b26226f25877255e61e8dca6a0689fc306817..dc25f640cb9feda6321d4284696fdee553de2c2b 100644 --- a/src/grouping/ptm/ptmgroupingexperiment.cpp +++ b/src/grouping/ptm/ptmgroupingexperiment.cpp @@ -99,7 +99,8 @@ PtmGroupingExperiment::getPtmIslandList() const void PtmGroupingExperiment::numbering() { - std::sort(_ptm_island_group_list.begin(), _ptm_island_group_list.end(), + std::sort(_ptm_island_group_list.begin(), + _ptm_island_group_list.end(), [](const PtmIslandGroupSp a, const PtmIslandGroupSp b) { return *(a.get()) < *(b.get()); }); @@ -192,7 +193,8 @@ PtmGroupingExperiment::mergePeptideMatchPtmIslandList( for(PtmIslandSp ptm_island_sp : ptm_island_list) { // http://en.cppreference.com/w/cpp/algorithm/all_any_none_of - if(std::none_of(new_ptm_island_list.begin(), new_ptm_island_list.end(), + if(std::none_of(new_ptm_island_list.begin(), + new_ptm_island_list.end(), [ptm_island_sp](PtmIslandSp element) { return element.get()->merge(ptm_island_sp); })) diff --git a/src/grouping/ptm/ptmisland.cpp b/src/grouping/ptm/ptmisland.cpp index 98c15f4a205e5caceccdb4c6a74da173cfb071b3..17cc60d32efac94a1ef1b27d41b9af1a2ab2ca92 100644 --- a/src/grouping/ptm/ptmisland.cpp +++ b/src/grouping/ptm/ptmisland.cpp @@ -152,7 +152,8 @@ bool PtmIsland::containsPeptideMatch(const PeptideMatch &peptide_match) const { - return std::any_of(_peptide_match_list.begin(), _peptide_match_list.end(), + return std::any_of(_peptide_match_list.begin(), + _peptide_match_list.end(), [peptide_match](const PeptideMatch &element) { return (peptide_match == element); }); @@ -199,7 +200,8 @@ PtmIsland::getProteinStartPosition() const bool PtmIsland::merge(PtmIslandSp ptm_island_sp) { - if(std::none_of(_peptide_match_list.begin(), _peptide_match_list.end(), + if(std::none_of(_peptide_match_list.begin(), + _peptide_match_list.end(), [ptm_island_sp](const PeptideMatch &element) { return ptm_island_sp.get()->containsPeptideMatch(element); })) @@ -213,7 +215,8 @@ PtmIsland::merge(PtmIslandSp ptm_island_sp) _peptide_match_list.begin(), ptm_island_sp.get()->_peptide_match_list.begin(), ptm_island_sp.get()->_peptide_match_list.end()); - std::sort(_peptide_match_list.begin(), _peptide_match_list.end(), + std::sort(_peptide_match_list.begin(), + _peptide_match_list.end(), [](const PeptideMatch &a, const PeptideMatch &b) { return (a.operator<(b)); }); @@ -231,14 +234,16 @@ PtmIsland::merge(PtmIslandSp ptm_island_sp) std::vector<PeptideMatch>::const_iterator it_result = - std::max_element(_peptide_match_list.begin(), _peptide_match_list.end(), + std::max_element(_peptide_match_list.begin(), + _peptide_match_list.end(), [](const PeptideMatch &a, const PeptideMatch &b) { return (a.getStop() < b.getStop()); }); _protein_stop = it_result->getStop(); it_result = - std::min_element(_peptide_match_list.begin(), _peptide_match_list.end(), + std::min_element(_peptide_match_list.begin(), + _peptide_match_list.end(), [](const PeptideMatch &a, const PeptideMatch &b) { return a.getStart() < b.getStart(); }); diff --git a/src/grouping/ptm/ptmislandgroup.cpp b/src/grouping/ptm/ptmislandgroup.cpp index 0f3a2b3843cc90cc434e0dba4634b5a567ba7e09..ca793c67f86b0039aeb8590bfe9a9ba161ba60cf 100644 --- a/src/grouping/ptm/ptmislandgroup.cpp +++ b/src/grouping/ptm/ptmislandgroup.cpp @@ -80,7 +80,8 @@ PtmIslandGroup::setGroupNumber(unsigned int number) { ptm_island_subgroup.get()->setPtmIslandGroup(this); } - std::sort(_ptm_island_subgroup_list.begin(), _ptm_island_subgroup_list.end(), + std::sort(_ptm_island_subgroup_list.begin(), + _ptm_island_subgroup_list.end(), [](const PtmIslandSubgroupSp &a, const PtmIslandSubgroupSp &b) { return (a.get()->getFirstPtmIsland()->getProteinStartPosition() < b.get()->getFirstPtmIsland()->getProteinStartPosition()); @@ -116,7 +117,8 @@ unsigned int PtmIslandGroup::maxCountSampleScan() const { std::vector<PtmIslandSubgroupSp>::const_iterator it_result = std::max_element( - _ptm_island_subgroup_list.begin(), _ptm_island_subgroup_list.end(), + _ptm_island_subgroup_list.begin(), + _ptm_island_subgroup_list.end(), [](const PtmIslandSubgroupSp &a, const PtmIslandSubgroupSp &b) { return (a.get()->countSampleScan() < b.get()->countSampleScan()); }); diff --git a/src/grouping/ptm/ptmislandsubgroup.cpp b/src/grouping/ptm/ptmislandsubgroup.cpp index d43c016a88b6ab81de3aa763192dfd0517f50d6f..7a5c334e4be5dd377bf2eb7d13bce429056f434a 100644 --- a/src/grouping/ptm/ptmislandsubgroup.cpp +++ b/src/grouping/ptm/ptmislandsubgroup.cpp @@ -73,7 +73,8 @@ PtmIslandSubgroup::setSubgroupNumber(unsigned int number) ptm_island.get()->setPtmIslandSubgroup(this); } std::sort( - _ptm_island_list.begin(), _ptm_island_list.end(), + _ptm_island_list.begin(), + _ptm_island_list.end(), [](const PtmIslandSp &a, const PtmIslandSp &b) { return ( a.get()->getProteinMatch()->getProteinXtpSp().get()->getAccession() < @@ -92,7 +93,8 @@ PtmIslandSubgroup::setPtmIslandGroup(PtmIslandGroup *p_ptm_island_group) { _ptm_island_group_p = p_ptm_island_group; std::sort( - _ptm_island_list.begin(), _ptm_island_list.end(), + _ptm_island_list.begin(), + _ptm_island_list.end(), [](const PtmIslandSp &a, const PtmIslandSp &b) { return ( a.get()->getProteinMatch()->getProteinXtpSp().get()->getAccession() < diff --git a/src/grouping/ptm/ptmsamplescan.cpp b/src/grouping/ptm/ptmsamplescan.cpp index 623eb6d9d4560d27fa637695c9394ef8f0afef56..3837399f20a4b9d18ae10a00ac93fb26d4850d1b 100644 --- a/src/grouping/ptm/ptmsamplescan.cpp +++ b/src/grouping/ptm/ptmsamplescan.cpp @@ -95,7 +95,8 @@ PtmSampleScan::add(const PeptideMatch &peptide_match) // qDebug() << __FILE__ << " " << __FUNCTION__<< " " << __LINE__ ; // sort list - std::sort(_peptide_match_list.begin(), _peptide_match_list.end(), + std::sort(_peptide_match_list.begin(), + _peptide_match_list.end(), [](const PeptideMatch &first, const PeptideMatch &second) { return (first.getPeptideEvidence()->getEvalue() < second.getPeptideEvidence()->getEvalue()); diff --git a/src/gui/about_dialog/aboutdialog.h b/src/gui/about_dialog/aboutdialog.h index fe2b90f2b675fff928daa1702965bd0c42070983..260a0435210534fadee1a3c392c51097502d4e8f 100644 --- a/src/gui/about_dialog/aboutdialog.h +++ b/src/gui/about_dialog/aboutdialog.h @@ -30,7 +30,7 @@ namespace Ui { - class AboutDialog; +class AboutDialog; } class AboutDialog : public QDialog diff --git a/src/gui/choose_modification_dialog/choosemodificationdialog.cpp b/src/gui/choose_modification_dialog/choosemodificationdialog.cpp index e1d4d90a849d19cb5039226081ce5dc28849a556..1a9fd625658a77ae0815b30e09b009d82cca5551 100644 --- a/src/gui/choose_modification_dialog/choosemodificationdialog.cpp +++ b/src/gui/choose_modification_dialog/choosemodificationdialog.cpp @@ -48,17 +48,25 @@ ChooseModificationDialog::ChooseModificationDialog(QWidget *parent) #if QT_VERSION >= 0x050000 // Qt5 code - connect(ui->modification_listview, &QListView::clicked, this, + connect(ui->modification_listview, + &QListView::clicked, + this, &ChooseModificationDialog::ItemClicked); - connect(ui->modification_listview, &QListView::doubleClicked, this, + connect(ui->modification_listview, + &QListView::doubleClicked, + this, &ChooseModificationDialog::ItemDoubleClicked); #else // Qt4 code - connect(ui->modification_listview, SIGNAL(clicked(const QModelIndex)), this, + connect(ui->modification_listview, + SIGNAL(clicked(const QModelIndex)), + this, SLOT(ItemClicked(QModelIndex))); - connect(ui->modification_listview, SIGNAL(doubleClicked(const QModelIndex)), - this, SLOT(ItemDoubleClicked(QModelIndex))); + connect(ui->modification_listview, + SIGNAL(doubleClicked(const QModelIndex)), + this, + SLOT(ItemDoubleClicked(QModelIndex))); #endif } diff --git a/src/gui/choose_modification_dialog/choosemodificationdialog.h b/src/gui/choose_modification_dialog/choosemodificationdialog.h index 2b5e42b25bdc0ebc58793b5687d833be06717148..c641196ff83e978e3505103e76dd3d348cee0270 100644 --- a/src/gui/choose_modification_dialog/choosemodificationdialog.h +++ b/src/gui/choose_modification_dialog/choosemodificationdialog.h @@ -33,7 +33,7 @@ namespace Ui { - class ChooseModificationDialog; +class ChooseModificationDialog; } class ChooseModificationDialog : public QDialog diff --git a/src/gui/edit/edit_label_methods/editlabelmethods.h b/src/gui/edit/edit_label_methods/editlabelmethods.h index 0a3d3dbdc29fef1d4f2e5b503530582c4c46000a..4d5bcd12386c4f30423eb87295f858447b07c5c3 100644 --- a/src/gui/edit/edit_label_methods/editlabelmethods.h +++ b/src/gui/edit/edit_label_methods/editlabelmethods.h @@ -35,7 +35,7 @@ class ProjectWindow; namespace Ui { - class EditLabelMethodView; +class EditLabelMethodView; } class EditLabelMethods : public QDialog diff --git a/src/gui/edit/edit_modifications/editmodifications.h b/src/gui/edit/edit_modifications/editmodifications.h index 8a57d416b49eb27ab0e0305f100e5eca47877bf5..08f50afe3d92f9ea00a2a30e52c7945768efd7dc 100644 --- a/src/gui/edit/edit_modifications/editmodifications.h +++ b/src/gui/edit/edit_modifications/editmodifications.h @@ -34,7 +34,7 @@ class ProjectWindow; // http://doc.qt.io/qt-4.8/qt-itemviews-chart-mainwindow-cpp.html namespace Ui { - class EditModificationView; +class EditModificationView; } class EditModifications : public QMainWindow diff --git a/src/gui/export/export_masschroq_dialog/exportmasschroqdialog.h b/src/gui/export/export_masschroq_dialog/exportmasschroqdialog.h index 26f0d1e6959ef71fe6af00ec62580377905c08a6..4e6951333f09638e1171e0aa443b196168bd0c70 100644 --- a/src/gui/export/export_masschroq_dialog/exportmasschroqdialog.h +++ b/src/gui/export/export_masschroq_dialog/exportmasschroqdialog.h @@ -80,5 +80,4 @@ class ExportMasschroqDialog : public QDialog private: void fillMsrunListComboBox(); - }; diff --git a/src/gui/lists/ms_identification_run_list_view/ms_identification_worker/msidlistworkerstatus.cpp b/src/gui/lists/ms_identification_run_list_view/ms_identification_worker/msidlistworkerstatus.cpp index 103a17846856a99644ab641729c68fe36d578855..dc17389ab82b9cac85f8f66aba03a4169dc1b0d7 100644 --- a/src/gui/lists/ms_identification_run_list_view/ms_identification_worker/msidlistworkerstatus.cpp +++ b/src/gui/lists/ms_identification_run_list_view/ms_identification_worker/msidlistworkerstatus.cpp @@ -153,6 +153,51 @@ MsIdListWorkerStatus::getStatus( void MsIdListWorkerStatus::doComputeMsNumber( IdentificationDataSourceSp identificationDataSource) +{ + if(QFileInfo(identificationDataSource.get()->getMsRunSp()->getFileName()) + .completeSuffix() == "tdf") + { + doComputeMsNumberForTDF(identificationDataSource); + } + else + { + doComputeMsNumberForMzXML(identificationDataSource); + } +} + +void +MsIdListWorkerStatus::changeWaitingQueue(int row) +{ + m_waitingComputing.clear(); + qDebug() << m_waitingComputing.size(); +} + +void +MsIdListWorkerStatus::doComputeMsNumberForTDF( + IdentificationDataSourceSp identificationDataSource) +{ + if(identificationDataSource->getMsRunSp()->findMsRunFile()) + { + try + { + } + catch(pappso::PappsoException &error) + { + // error while computing + qDebug() << error.qwhat(); + m_identificationError.push_back(identificationDataSource.get()); + } + } + else + { + // file not found + m_identificationFileNotFound.push_back(identificationDataSource.get()); + } +} + +void +MsIdListWorkerStatus::doComputeMsNumberForMzXML( + IdentificationDataSourceSp identificationDataSource) { pappso::MsRunReaderSPtr msrun_reader_sp = identificationDataSource->getMsRunSp().get()->getMsRunReaderSPtr(); @@ -209,10 +254,3 @@ MsIdListWorkerStatus::doComputeMsNumber( m_identificationFileNotFound.push_back(identificationDataSource.get()); } } - -void -MsIdListWorkerStatus::changeWaitingQueue(int row) -{ - m_waitingComputing.clear(); - qDebug() << m_waitingComputing.size(); -} diff --git a/src/gui/lists/ms_identification_run_list_view/ms_identification_worker/msidlistworkerstatus.h b/src/gui/lists/ms_identification_run_list_view/ms_identification_worker/msidlistworkerstatus.h index 92661506d2a6d8a585b81e2a775ae36a4db1d252..2eb70ea9269896c4fdd72f9655d9dda2d6915bcd 100644 --- a/src/gui/lists/ms_identification_run_list_view/ms_identification_worker/msidlistworkerstatus.h +++ b/src/gui/lists/ms_identification_run_list_view/ms_identification_worker/msidlistworkerstatus.h @@ -63,6 +63,7 @@ enum class WorkerStatus : std::int8_t Ready = 3, NotReady = 4, Error = 5, + NotAvailable = 6, }; class MsIdentificationListWindow; class MsIdListWorkerStatus @@ -77,6 +78,8 @@ class MsIdListWorkerStatus */ WorkerStatus getStatus(IdentificationDataSourceSp identificationDataSource); void doComputeMsNumber(IdentificationDataSourceSp identificationDataSource); + void doComputeMsNumberForTDF(IdentificationDataSourceSp identificationDataSource); + void doComputeMsNumberForMzXML(IdentificationDataSourceSp identificationDataSource); void changeWaitingQueue(int row); diff --git a/src/gui/lists/ms_identification_run_list_view/msidentificationtablemodel.cpp b/src/gui/lists/ms_identification_run_list_view/msidentificationtablemodel.cpp index 337da3be161457a4b70b1c9e97f7c6d1137a6cc5..9280959d6c30cf59db87b1cba3d00f3f3c7b0552 100644 --- a/src/gui/lists/ms_identification_run_list_view/msidentificationtablemodel.cpp +++ b/src/gui/lists/ms_identification_run_list_view/msidentificationtablemodel.cpp @@ -400,8 +400,18 @@ MsIdentificationTableModel::data(const QModelIndex &index, int role) const } if(col == (std::int8_t)msIdentificationListColumn::nb_tic_1) { + // if(QFileInfo(m_identificationDataSourceSpList.at(row) + // ->getMsRunSp() + // ->getFileName()) + // .completeSuffix() == "tdf") + // { + // return QVariant("NA"); + // } + // else + // { return getMsRunStatisticsNumber(row, MsRunStatistics::tic_spectra_ms1); + // } } if(col == (std::int8_t)msIdentificationListColumn::nb_tic_2) { @@ -551,9 +561,8 @@ MsIdentificationTableModel::getMsRunStatisticsNumber( switch(temp) { case WorkerStatus::Ready: - var_return = m_identificationDataSourceSpList.at(row) - ->getMsRunSp() - ->getMsRunStatistics(column); + var_return = getMsRunStatisticsFollowingFormat( + m_identificationDataSourceSpList.at(row)->getMsRunSp(), column); emit projectStatusChanged(); break; case WorkerStatus::NotReady: @@ -618,3 +627,28 @@ MsIdentificationTableModel::stopThreads() { msp_workerStatus.get()->stopThreads(); } + +QVariant +MsIdentificationTableModel::getMsRunStatisticsFollowingFormat( + MsRunSp msrun_sp, MsRunStatistics column) const +{ + QString raw_format = QFileInfo(msrun_sp->getFileName()).completeSuffix(); + + if(raw_format != "tdf") + { + return msrun_sp->getMsRunStatistics(column); + } + else + { + if(column == MsRunStatistics::tic_spectra_ms1 || + column == MsRunStatistics::tic_spectra_ms2 || + column == MsRunStatistics::tic_spectra_ms3) + { + return QVariant("NA"); + } + else + { + return msrun_sp->getMsRunStatistics(column); + } + } +} diff --git a/src/gui/lists/ms_identification_run_list_view/msidentificationtablemodel.h b/src/gui/lists/ms_identification_run_list_view/msidentificationtablemodel.h index 38ed79dcd7c02e2a3faa5a8007e89322769d5ebe..c43fb92062ab29808d8452af779837d3dd1cb167 100644 --- a/src/gui/lists/ms_identification_run_list_view/msidentificationtablemodel.h +++ b/src/gui/lists/ms_identification_run_list_view/msidentificationtablemodel.h @@ -109,6 +109,7 @@ class MsIdentificationTableModel : public QAbstractTableModel private: static int getColumnWidth(int column); + QVariant getMsRunStatisticsFollowingFormat(MsRunSp msrun_sp, MsRunStatistics column) const; private: std::vector<IdentificationDataSourceSp> m_identificationDataSourceSpList; diff --git a/src/gui/load_results_dialog/loadresultsdialog.cpp b/src/gui/load_results_dialog/loadresultsdialog.cpp index 97990c182fc60b02b9b74a30a1559c75f7553f72..167008e62186331a9c513150ae2b92f93cce25da 100644 --- a/src/gui/load_results_dialog/loadresultsdialog.cpp +++ b/src/gui/load_results_dialog/loadresultsdialog.cpp @@ -53,7 +53,8 @@ LoadResultsDialog::LoadResultsDialog(QWidget *parent) settings.value("automatic_filter/protein_evalue", "0.01").toDouble()); ui->automatic_filter_widget->setAutomaticFilterParameters(param); - setMinimumWidth(ui->automatic_filter_widget->getAutomaticFilterWindowWidth() + 200); + setMinimumWidth(ui->automatic_filter_widget->getAutomaticFilterWindowWidth() + + 200); #if QT_VERSION >= 0x050000 // Qt5 code diff --git a/src/gui/load_results_dialog/loadresultsdialog.h b/src/gui/load_results_dialog/loadresultsdialog.h index 613e058c2f3d273e1a51cb210692da82f4b2660e..6ba44e428100e6f2623bc8daef725dda77b79e40 100644 --- a/src/gui/load_results_dialog/loadresultsdialog.h +++ b/src/gui/load_results_dialog/loadresultsdialog.h @@ -33,7 +33,7 @@ namespace Ui { - class LoadResultsDialog; +class LoadResultsDialog; } diff --git a/src/gui/peptide_list_view/peptidetableproxymodel.h b/src/gui/peptide_list_view/peptidetableproxymodel.h index 569bc20165262113be3f1f742115c9b48e215375..123ce4b4f71c0cd4ea9c98bb9ff6a14153bad3f6 100644 --- a/src/gui/peptide_list_view/peptidetableproxymodel.h +++ b/src/gui/peptide_list_view/peptidetableproxymodel.h @@ -47,8 +47,8 @@ class PeptideTableProxyModel : public QSortFilterProxyModel bool filterAcceptsColumn(int source_column, const QModelIndex &source_parent) const override; - QVariant headerData(int section, Qt::Orientation orientation, - int role) const override; + QVariant + headerData(int section, Qt::Orientation orientation, int role) const override; QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const override; bool lessThan(const QModelIndex &left, diff --git a/src/gui/project_view/identification_group_widget/identificationgroupwidget.h b/src/gui/project_view/identification_group_widget/identificationgroupwidget.h index 14da2a0538d5a737c6a4e9a58efaef41fe3091c6..764eb25479fa7df4e2a12a0bc939bffd255c32d6 100644 --- a/src/gui/project_view/identification_group_widget/identificationgroupwidget.h +++ b/src/gui/project_view/identification_group_widget/identificationgroupwidget.h @@ -28,7 +28,7 @@ namespace Ui { - class IdentificationGroupWidget; +class IdentificationGroupWidget; } diff --git a/src/gui/protein_list_view/proteinlistwindow.h b/src/gui/protein_list_view/proteinlistwindow.h index d3e5665ef4b50a22fb38309ed147ec0106c1647b..246e3d0c64933599e953409697feaf454aaae74e 100644 --- a/src/gui/protein_list_view/proteinlistwindow.h +++ b/src/gui/protein_list_view/proteinlistwindow.h @@ -85,8 +85,8 @@ class ProteinListWindow : public QMainWindow signals: void identificationGroupEdited(IdentificationGroup *p_identification_group); void proteinDataChanged(); - void projectStatusChanged(); - + void projectStatusChanged(); + protected slots: void doNotValidHide(bool hide); void doNotCheckedHide(bool hide); diff --git a/src/gui/protein_list_view/proteintablemodel.cpp b/src/gui/protein_list_view/proteintablemodel.cpp index 490f40bb9af62e4406a2325e0be34d837bfa13f1..cbe0d4ec5f2a45efc88689b8402ea446fc9c957c 100644 --- a/src/gui/protein_list_view/proteintablemodel.cpp +++ b/src/gui/protein_list_view/proteintablemodel.cpp @@ -209,7 +209,8 @@ ProteinTableModel::getDescription(std::int8_t column) return ""; } QVariant -ProteinTableModel::headerData(int section, Qt::Orientation orientation, +ProteinTableModel::headerData(int section, + Qt::Orientation orientation, int role) const { if(_p_identification_group == nullptr) diff --git a/src/gui/protein_list_view/proteintablemodel.h b/src/gui/protein_list_view/proteintablemodel.h index 1a38de15833cd20321296ac3ad362cf0b364f117..a55106b1e15de0c39b92a34537661346c66fec17 100644 --- a/src/gui/protein_list_view/proteintablemodel.h +++ b/src/gui/protein_list_view/proteintablemodel.h @@ -61,8 +61,8 @@ class ProteinTableModel : public QAbstractTableModel rowCount(const QModelIndex &parent = QModelIndex()) const override; virtual int columnCount(const QModelIndex &parent = QModelIndex()) const override; - virtual QVariant headerData(int section, Qt::Orientation orientation, - int role) const override; + virtual QVariant + headerData(int section, Qt::Orientation orientation, int role) const override; virtual QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const override; @@ -75,7 +75,7 @@ class ProteinTableModel : public QAbstractTableModel void setIdentificationGroup(IdentificationGroup *p_identification_group); IdentificationGroup *getIdentificationGroup(); - + public slots: void onProteinDataChanged(); diff --git a/src/gui/protein_list_view/proteintableproxymodel.h b/src/gui/protein_list_view/proteintableproxymodel.h index adefbcb080a05dd1168a1d9e1232a685c7adb328..d4f6877009bef5cb49ad67d901df975fa9b38be2 100644 --- a/src/gui/protein_list_view/proteintableproxymodel.h +++ b/src/gui/protein_list_view/proteintableproxymodel.h @@ -48,8 +48,8 @@ class ProteinTableProxyModel : public QSortFilterProxyModel bool filterAcceptsColumn(int source_column, const QModelIndex &source_parent) const override; - QVariant headerData(int section, Qt::Orientation orientation, - int role) const override; + QVariant + headerData(int section, Qt::Orientation orientation, int role) const override; QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const override; bool lessThan(const QModelIndex &left, diff --git a/src/gui/ptm_island_list_view/ptmislandlistwindow.cpp b/src/gui/ptm_island_list_view/ptmislandlistwindow.cpp index 5332863201b216df673981bc7541b561417597ec..b9a80f64932f4771d7b12cfd1242cf09d7aa3cab 100644 --- a/src/gui/ptm_island_list_view/ptmislandlistwindow.cpp +++ b/src/gui/ptm_island_list_view/ptmislandlistwindow.cpp @@ -63,30 +63,46 @@ PtmIslandListWindow::PtmIslandListWindow(ProjectWindow *parent) #if QT_VERSION >= 0x050000 // Qt5 code - connect(this, &PtmIslandListWindow::ptmIslandDataChanged, _ptm_table_model_p, + connect(this, + &PtmIslandListWindow::ptmIslandDataChanged, + _ptm_table_model_p, &PtmIslandTableModel::onPtmIslandDataChanged); - connect(_project_window, &ProjectWindow::identificationPtmGroupGrouped, this, + connect(_project_window, + &ProjectWindow::identificationPtmGroupGrouped, + this, &PtmIslandListWindow::doIdentificationPtmGroupGrouped); - connect(_project_window, &ProjectWindow::identificationGroupGrouped, this, + connect(_project_window, + &ProjectWindow::identificationGroupGrouped, + this, &PtmIslandListWindow::doIdentificationGroupGrouped); - connect(ui->ptm_island_tableview, &QTableView::clicked, _ptm_proxy_model_p, + connect(ui->ptm_island_tableview, + &QTableView::clicked, + _ptm_proxy_model_p, &PtmIslandProxyModel::onTableClicked); - connect(_ptm_table_model_p, &PtmIslandTableModel::layoutChanged, this, + connect(_ptm_table_model_p, + &PtmIslandTableModel::layoutChanged, + this, &PtmIslandListWindow::updateStatusBar); #else // Qt4 code - connect(this, SIGNAL(ptmIslandDataChanged()), _ptm_table_model_p, + connect(this, + SIGNAL(ptmIslandDataChanged()), + _ptm_table_model_p, SLOT(onPtmIslandDataChanged())); connect(_project_window, - SIGNAL(identificationPtmGroupGrouped(IdentificationGroup *)), this, + SIGNAL(identificationPtmGroupGrouped(IdentificationGroup *)), + this, SLOT(doIdentificationPtmGroupGrouped(IdentificationGroup *))); connect(_project_window, - SIGNAL(identificationGroupGrouped(IdentificationGroup *)), this, + SIGNAL(identificationGroupGrouped(IdentificationGroup *)), + this, SLOT(doIdentificationGroupGrouped(IdentificationGroup *))); - connect(ui->ptm_island_tableview, SIGNAL(clicked(const QModelIndex &)), - _ptm_proxy_model_p, SLOT(onTableClicked(const QModelIndex &))); + connect(ui->ptm_island_tableview, + SIGNAL(clicked(const QModelIndex &)), + _ptm_proxy_model_p, + SLOT(onTableClicked(const QModelIndex &))); #endif } diff --git a/src/gui/ptm_island_list_view/ptmislandlistwindow.h b/src/gui/ptm_island_list_view/ptmislandlistwindow.h index 70cb8e16864ed226b8bd6f18e014e76351cec23c..e5f49d377f648a53de01181f83308767ad0203ca 100644 --- a/src/gui/ptm_island_list_view/ptmislandlistwindow.h +++ b/src/gui/ptm_island_list_view/ptmislandlistwindow.h @@ -42,7 +42,7 @@ class PtmPeptideListWindow; // http://doc.qt.io/qt-4.8/qt-itemviews-chart-mainwindow-cpp.html namespace Ui { - class PtmIslandListWindow; +class PtmIslandListWindow; } class PtmIslandListWindow : public QMainWindow diff --git a/src/gui/ptm_island_list_view/ptmislandtablemodel.cpp b/src/gui/ptm_island_list_view/ptmislandtablemodel.cpp index d039db1fe402edff4d6d9ff8fcea4b678fba7991..9057339b4609e74b2b55246ac43768cc8861bda7 100644 --- a/src/gui/ptm_island_list_view/ptmislandtablemodel.cpp +++ b/src/gui/ptm_island_list_view/ptmislandtablemodel.cpp @@ -178,7 +178,8 @@ PtmIslandTableModel::columnCount(const QModelIndex &parent) const return 0; } QVariant -PtmIslandTableModel::headerData(int section, Qt::Orientation orientation, +PtmIslandTableModel::headerData(int section, + Qt::Orientation orientation, int role) const { if(getPtmGroupingExperiment() == nullptr) diff --git a/src/gui/ptm_island_list_view/ptmislandtablemodel.h b/src/gui/ptm_island_list_view/ptmislandtablemodel.h index 2cee9bc6260f1f14c7bd0a7ab96649de8104208e..da20d0d4ad2383fea2d4f1c4d4af2f325e897c21 100644 --- a/src/gui/ptm_island_list_view/ptmislandtablemodel.h +++ b/src/gui/ptm_island_list_view/ptmislandtablemodel.h @@ -70,8 +70,8 @@ class PtmIslandTableModel : public QAbstractTableModel rowCount(const QModelIndex &parent = QModelIndex()) const override; virtual int columnCount(const QModelIndex &parent = QModelIndex()) const override; - virtual QVariant headerData(int section, Qt::Orientation orientation, - int role) const override; + virtual QVariant + headerData(int section, Qt::Orientation orientation, int role) const override; virtual QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const override; diff --git a/src/gui/ptm_peptide_list_view/ptmpeptidelistwindow.cpp b/src/gui/ptm_peptide_list_view/ptmpeptidelistwindow.cpp index 2eb2a838211e1e2b446934993cc5b0956d4662da..6113bd9e0e2c82921ff59c06a1a51aa3273a00ca 100644 --- a/src/gui/ptm_peptide_list_view/ptmpeptidelistwindow.cpp +++ b/src/gui/ptm_peptide_list_view/ptmpeptidelistwindow.cpp @@ -55,7 +55,7 @@ PtmPeptideListWindow::PtmPeptideListWindow(PtmIslandListWindow *parent) ui->ptm_peptide_tableview->setSortingEnabled(true); ui->ptm_peptide_tableview->setAlternatingRowColors(true); ui->ptm_peptide_tableview->horizontalHeader()->setSectionsMovable(true); - + PtmSequenceDelegate *p_sequence_delegate = new PtmSequenceDelegate(_p_ptm_island_list_window, this); ui->ptm_peptide_tableview->setItemDelegateForColumn( @@ -64,9 +64,12 @@ PtmPeptideListWindow::PtmPeptideListWindow(PtmIslandListWindow *parent) #if QT_VERSION >= 0x050000 // Qt5 code - connect(ui->ptm_peptide_tableview, &QTableView::clicked, _ptm_proxy_model_p, + connect(ui->ptm_peptide_tableview, + &QTableView::clicked, + _ptm_proxy_model_p, &PtmPeptideTableProxyModel::onTableClicked); - connect(this, &PtmPeptideListWindow::requestPeptideDetailView, + connect(this, + &PtmPeptideListWindow::requestPeptideDetailView, _p_ptm_island_list_window->getProjectWindowP(), &ProjectWindow::doViewPeptideDetail); #else @@ -79,9 +82,12 @@ PtmPeptideListWindow::PtmPeptideListWindow(PtmIslandListWindow *parent) // this,SLOT(doIdentificationPtmGroupGrouped(IdentificationGroup *))); connect // (_project_window, SIGNAL(identificationGroupGrouped(IdentificationGroup // *)), this,SLOT(doIdentificationGroupGrouped(IdentificationGroup *))); - connect(ui->ptm_peptide_tableview, SIGNAL(clicked(const QModelIndex &)), - _ptm_proxy_model_p, SLOT(onTableClicked(const QModelIndex &))); - connect(this, SIGNAL(requestPeptideDetailView(PeptideMatch *)), + connect(ui->ptm_peptide_tableview, + SIGNAL(clicked(const QModelIndex &)), + _ptm_proxy_model_p, + SLOT(onTableClicked(const QModelIndex &))); + connect(this, + SIGNAL(requestPeptideDetailView(PeptideMatch *)), _p_ptm_island_list_window->getProjectWindowP(), SLOT(doViewPeptideDetail(PeptideMatch *))); diff --git a/src/gui/ptm_peptide_list_view/ptmpeptidelistwindow.h b/src/gui/ptm_peptide_list_view/ptmpeptidelistwindow.h index d49489ef74f2197e0e22c0dca384ecd5e8b6046c..b4bcc15c85df99bace9e68394e114e486390abe4 100644 --- a/src/gui/ptm_peptide_list_view/ptmpeptidelistwindow.h +++ b/src/gui/ptm_peptide_list_view/ptmpeptidelistwindow.h @@ -40,7 +40,7 @@ class PtmIslandListWindow; namespace Ui { - class PtmPeptideListWindow; +class PtmPeptideListWindow; } diff --git a/src/gui/ptm_peptide_list_view/ptmpeptidetablemodel.cpp b/src/gui/ptm_peptide_list_view/ptmpeptidetablemodel.cpp index ba001ecf8089b26cf8ec4a01315071967b31f549..9ccc8b593e3b5c92263f20d6ccf57954771cb0a8 100644 --- a/src/gui/ptm_peptide_list_view/ptmpeptidetablemodel.cpp +++ b/src/gui/ptm_peptide_list_view/ptmpeptidetablemodel.cpp @@ -188,7 +188,8 @@ PtmPeptideTableModel::columnCount(const QModelIndex &parent) const return 15; } QVariant -PtmPeptideTableModel::headerData(int section, Qt::Orientation orientation, +PtmPeptideTableModel::headerData(int section, + Qt::Orientation orientation, int role) const { if(orientation == Qt::Horizontal) diff --git a/src/gui/ptm_peptide_list_view/ptmpeptidetablemodel.h b/src/gui/ptm_peptide_list_view/ptmpeptidetablemodel.h index 76c02ce65b2f5ac008d2fe0dbb74427e876171c1..59ae2434804153b5a49fa749f55a2109ace9bee6 100644 --- a/src/gui/ptm_peptide_list_view/ptmpeptidetablemodel.h +++ b/src/gui/ptm_peptide_list_view/ptmpeptidetablemodel.h @@ -71,8 +71,8 @@ class PtmPeptideTableModel : public QAbstractTableModel rowCount(const QModelIndex &parent = QModelIndex()) const override; virtual int columnCount(const QModelIndex &parent = QModelIndex()) const override; - virtual QVariant headerData(int section, Qt::Orientation orientation, - int role) const override; + virtual QVariant + headerData(int section, Qt::Orientation orientation, int role) const override; virtual QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const override; static const QString getTitle(PtmPeptideListColumn column); diff --git a/src/gui/ptm_peptide_list_view/ptmpeptidetableproxymodel.cpp b/src/gui/ptm_peptide_list_view/ptmpeptidetableproxymodel.cpp index 4a15cc5482239dab46574bb158344a958be9bf97..e370564136dc0eccf7208453cdff35adb2401e18 100644 --- a/src/gui/ptm_peptide_list_view/ptmpeptidetableproxymodel.cpp +++ b/src/gui/ptm_peptide_list_view/ptmpeptidetableproxymodel.cpp @@ -35,7 +35,8 @@ PtmPeptideMenuQicon::PtmPeptideMenuQicon( const PtmGroupingExperiment *p_ptm_grouping_experiment, - const PtmSampleScan *p_ptm_sample, const PeptideMatch *p_peptide_match) + const PtmSampleScan *p_ptm_sample, + const PeptideMatch *p_peptide_match) : QIcon(), _peptide_match(*p_peptide_match) { _p_ptm_sample_scan = p_ptm_sample; @@ -45,8 +46,10 @@ PtmPeptideMenuQicon::~PtmPeptideMenuQicon() { } void -PtmPeptideMenuQicon::paint(QPainter *painter, const QRect &rect, - Qt::Alignment alignment, Mode mode, +PtmPeptideMenuQicon::paint(QPainter *painter, + const QRect &rect, + Qt::Alignment alignment, + Mode mode, State state) const { @@ -69,14 +72,15 @@ PtmPeptideMenuQicon::paint(QPainter *painter, const QRect &rect, PtmPeptideMenuQaction::PtmPeptideMenuQaction( PtmPeptideTableProxyModel *parent, const PtmGroupingExperiment *p_ptm_grouping_experiment, - const PtmSampleScan *p_ptm_sample, PeptideMatch *p_peptide_match) + const PtmSampleScan *p_ptm_sample, + PeptideMatch *p_peptide_match) : QAction(parent) { _p_ptm_peptide_table_proxy_model = parent; _peptide_match = *p_peptide_match; - this->setIcon(PtmPeptideMenuQicon(p_ptm_grouping_experiment, p_ptm_sample, - p_peptide_match)); + this->setIcon(PtmPeptideMenuQicon( + p_ptm_grouping_experiment, p_ptm_sample, p_peptide_match)); // this->setText(p_peptide_match->getPeptideXtpSp().get()->getSequence()); QStringList position_list; @@ -97,7 +101,9 @@ PtmPeptideMenuQaction::PtmPeptideMenuQaction( #if QT_VERSION >= 0x050000 // Qt5 code - connect(this, &PtmPeptideMenuQaction::triggered, this, + connect(this, + &PtmPeptideMenuQaction::triggered, + this, &PtmPeptideMenuQaction::doTriggered); #else // Qt4 code @@ -187,8 +193,10 @@ PtmPeptideTableProxyModel::showContextMenu(const QModelIndex &index) for(auto p_peptide_match : sp_ptm_sample_scan.get()->getPeptideMatchList()) { p_action = new PtmPeptideMenuQaction( - this, _p_ptm_table_model->getPtmGroupingExperiment(), - sp_ptm_sample_scan.get(), &p_peptide_match); + this, + _p_ptm_table_model->getPtmGroupingExperiment(), + sp_ptm_sample_scan.get(), + &p_peptide_match); _p_context_menu->addAction(p_action); } diff --git a/src/gui/ptm_peptide_list_view/ptmpeptidetableproxymodel.h b/src/gui/ptm_peptide_list_view/ptmpeptidetableproxymodel.h index 3b458883bfd391828b05e20202daed9b4270f104..fc1211eccfbb6a56297d0c021d1035a2e711e8b8 100644 --- a/src/gui/ptm_peptide_list_view/ptmpeptidetableproxymodel.h +++ b/src/gui/ptm_peptide_list_view/ptmpeptidetableproxymodel.h @@ -46,12 +46,15 @@ class PtmPeptideMenuQicon : public QIcon public: explicit PtmPeptideMenuQicon( const PtmGroupingExperiment *p_ptm_grouping_experiment, - const PtmSampleScan *p_ptm_sample, const PeptideMatch *p_peptide_match); + const PtmSampleScan *p_ptm_sample, + const PeptideMatch *p_peptide_match); ~PtmPeptideMenuQicon(); - void paint(QPainter *painter, const QRect &rect, - Qt::Alignment alignment = Qt::AlignCenter, Mode mode = Normal, - State state = Off) const; + void paint(QPainter *painter, + const QRect &rect, + Qt::Alignment alignment = Qt::AlignCenter, + Mode mode = Normal, + State state = Off) const; private: const PtmSampleScan *_p_ptm_sample_scan; @@ -66,7 +69,8 @@ class PtmPeptideMenuQaction : public QAction explicit PtmPeptideMenuQaction( PtmPeptideTableProxyModel *parent, const PtmGroupingExperiment *p_ptm_grouping_experiment, - const PtmSampleScan *p_ptm_sample, PeptideMatch *p_peptide_match); + const PtmSampleScan *p_ptm_sample, + PeptideMatch *p_peptide_match); ~PtmPeptideMenuQaction(); public slots: diff --git a/src/gui/ptm_peptide_list_view/ptmsequencedelegate.h b/src/gui/ptm_peptide_list_view/ptmsequencedelegate.h index e9b786bcc63c4700a6db961e0def62f88408155d..fef38bde8479a3fe0861ad335932e9ca63d6806e 100644 --- a/src/gui/ptm_peptide_list_view/ptmsequencedelegate.h +++ b/src/gui/ptm_peptide_list_view/ptmsequencedelegate.h @@ -41,7 +41,8 @@ class PtmSequenceDelegate : public QStyledItemDelegate PtmSequenceDelegate(PtmIslandListWindow *p_ptm_island_list_window, QWidget *parent = 0); - void paint(QPainter *painter, const QStyleOptionViewItem &option, + void paint(QPainter *painter, + const QStyleOptionViewItem &option, const QModelIndex &index) const override; // QSize sizeHint(const QStyleOptionViewItem &option, // const QModelIndex &index) const override; diff --git a/src/gui/tandem_run_dialog/tandemrundialog.cpp b/src/gui/tandem_run_dialog/tandemrundialog.cpp index d95cf3e2d93344aacb433255e15fff3dda330398..a48debfe03b8bbd13d50905553fa87ff9ff94575 100644 --- a/src/gui/tandem_run_dialog/tandemrundialog.cpp +++ b/src/gui/tandem_run_dialog/tandemrundialog.cpp @@ -389,8 +389,10 @@ TandemRunDialog::selectMzFiles() this, tr("select peak list files"), default_mz_location, - tr("any mz files (*.mzXML *.mzxml *.mzML *.mzml *.mgf *.tdf);;mzXML (*.mzXML " - "*.mzxml);;mzML (*.mzML *.mzml);;MGF (*.mgf);; tdf (*.tdf);;all files (*)")); + tr("any mz files (*.mzXML *.mzxml *.mzML *.mzml *.mgf *.tdf);;mzXML " + "(*.mzXML " + "*.mzxml);;mzML (*.mzML *.mzml);;MGF (*.mgf);; tdf (*.tdf);;all " + "files (*)")); if(filenames.size() > 0) { diff --git a/src/gui/tandem_run_dialog/tandemrundialog.h b/src/gui/tandem_run_dialog/tandemrundialog.h index 08ad646341b0c3d19c230011c5411d6b57b3c893..f2497ae6761b995343824813f9b2b4ad33f97685 100644 --- a/src/gui/tandem_run_dialog/tandemrundialog.h +++ b/src/gui/tandem_run_dialog/tandemrundialog.h @@ -33,7 +33,7 @@ namespace Ui { - class TandemRunDialog; +class TandemRunDialog; } diff --git a/src/gui/widgets/Alignment_group_menu/alignmentgroupmenu.cpp b/src/gui/widgets/Alignment_group_menu/alignmentgroupmenu.cpp index 7e486abd74631ef764707630f6a46d2d673e6b10..50c9f139b6c04e362d913ee8020c54ae53f4b96f 100644 --- a/src/gui/widgets/Alignment_group_menu/alignmentgroupmenu.cpp +++ b/src/gui/widgets/Alignment_group_menu/alignmentgroupmenu.cpp @@ -47,7 +47,8 @@ AlignmentGroupsQMenu::AlignmentGroupsQMenu(MsIdentificationListWindow *parent, QIcon *remove_reference_icon = new QIcon(":/icons/resources/icons/icon_remove_reference.svg"); - mp_removeReference = new QAction(*remove_reference_icon, tr("&Remove reference")); + mp_removeReference = + new QAction(*remove_reference_icon, tr("&Remove reference")); this->addAction(mp_removeReference); mp_ungroup = new QAction( @@ -95,9 +96,9 @@ AlignmentGroupsQMenu::createGroupsSubMenu() mp_subMenuGroup->addAction(mp_newGroup); mp_subMenuGroup->addSeparator(); foreach(MsRunAlignmentGroupSp group, mp_project->getMsRunAlignmentGroupList()) - { - mp_subMenuGroup->addAction(group->getMsRunAlignmentGroupName()); - } + { + mp_subMenuGroup->addAction(group->getMsRunAlignmentGroupName()); + } } void diff --git a/src/gui/widgets/automatic_filter_widget/automaticfilterwidget.cpp b/src/gui/widgets/automatic_filter_widget/automaticfilterwidget.cpp index 337d3348e5eae66761b5cfad08413a9d98cd520f..acd18feba3ab4b3f8ab2d2870ebb529b2160b10d 100644 --- a/src/gui/widgets/automatic_filter_widget/automaticfilterwidget.cpp +++ b/src/gui/widgets/automatic_filter_widget/automaticfilterwidget.cpp @@ -164,7 +164,7 @@ AutomaticFilterWidget::doSetParameters() { if(ui->fdr_radio_button->isChecked()) { - _parameters.setFilterPeptideFDR(ui->peptide_fdr_spinbox->value()/100); + _parameters.setFilterPeptideFDR(ui->peptide_fdr_spinbox->value() / 100); ui->peptide_evalue_spinbox->setDisabled(true); ui->peptide_fdr_spinbox->setEnabled(true); } @@ -179,7 +179,8 @@ AutomaticFilterWidget::doSetParameters() } -int AutomaticFilterWidget::getAutomaticFilterWindowWidth() const +int +AutomaticFilterWidget::getAutomaticFilterWindowWidth() const { return ui->gridLayout_2->minimumSize().width(); } diff --git a/src/gui/widgets/decoy_widget/decoywidget.cpp b/src/gui/widgets/decoy_widget/decoywidget.cpp index d627f397a4b85acb55af18cba69bca15885d2947..b2289982aa8d74e6c1012354d66238d43859f2bf 100644 --- a/src/gui/widgets/decoy_widget/decoywidget.cpp +++ b/src/gui/widgets/decoy_widget/decoywidget.cpp @@ -224,7 +224,9 @@ DecoyWidget::doSelectFastaFile() settings.value("path/fastafiles_directory", "").toString(); QStringList filenames = QFileDialog::getOpenFileNames( - this, tr("FASTA files"), default_fasta_location, + this, + tr("FASTA files"), + default_fasta_location, tr("FASTA files (*.fasta);;all files (*)")); if(filenames.size() > 0) diff --git a/src/gui/widgets/decoy_widget/decoywidget.h b/src/gui/widgets/decoy_widget/decoywidget.h index 4406058d17bc7acbbb4188a27d8b2945a9990422..9cd64c78643b8f0b568b7c24498611b137df46af 100644 --- a/src/gui/widgets/decoy_widget/decoywidget.h +++ b/src/gui/widgets/decoy_widget/decoywidget.h @@ -36,7 +36,7 @@ namespace Ui { - class DecoyWidget; +class DecoyWidget; } class DecoyWidget : public QWidget diff --git a/src/gui/widgets/xic_extraction_method_widget/xicextractionmethodwidget.h b/src/gui/widgets/xic_extraction_method_widget/xicextractionmethodwidget.h index 962543d9c2a4291d02e5ded2689c37a97640b9b7..63d8bf35a923ea58aadfc70f5f737302c0423793 100644 --- a/src/gui/widgets/xic_extraction_method_widget/xicextractionmethodwidget.h +++ b/src/gui/widgets/xic_extraction_method_widget/xicextractionmethodwidget.h @@ -49,8 +49,7 @@ class XicExtractionMethodWidget : public QWidget XicExtractionMethodWidget(QWidget *parent = 0); ~XicExtractionMethodWidget(); pappso::XicExtractMethod getXicExtractionMethod() const; - + signals: void xicExtractionMethodChanged(pappso::XicExtractMethod method) const; }; - diff --git a/src/gui/xic_view/xic_widgets/zivywidget.cpp b/src/gui/xic_view/xic_widgets/zivywidget.cpp index afc675f6d2f09bd47b529d3e6daec1d4db49bf32..b23fa95d483b68b95d24ad16bc265319adea0e10 100644 --- a/src/gui/xic_view/xic_widgets/zivywidget.cpp +++ b/src/gui/xic_view/xic_widgets/zivywidget.cpp @@ -37,10 +37,10 @@ std::shared_ptr<pappso::TraceDetectionInterface> ZivyParams::newTraceDetectionZivySPtr() const { return std::make_shared<pappso::TraceDetectionZivy>(_smoothing_half_window, - _minmax_half_window, - _maxmin_half_window, - _minmax_threshold, - _maxmin_threshold); + _minmax_half_window, + _maxmin_half_window, + _minmax_threshold, + _maxmin_threshold); } void diff --git a/src/gui/xic_view/xicworkerthread.cpp b/src/gui/xic_view/xicworkerthread.cpp index e038f058889cab4dee9be321119b7158fce333d8..910dbf4952ebbebe0d3e63f115ab97bf3414a3aa 100644 --- a/src/gui/xic_view/xicworkerthread.cpp +++ b/src/gui/xic_view/xicworkerthread.cpp @@ -98,7 +98,8 @@ XicWorkerThread::doComputeIsotopeMassList(pappso::PeptideSp peptide_sp, isotope_mass_list = isotope_list.getByIntensityRatio( charge, precision, minimum_isotope_pattern_ratio); - std::sort(isotope_mass_list.begin(), isotope_mass_list.end(), + std::sort(isotope_mass_list.begin(), + isotope_mass_list.end(), [](const pappso::PeptideNaturalIsotopeAverageSp &m, const pappso::PeptideNaturalIsotopeAverageSp &n) -> bool { unsigned int mn(m.get()->getIsotopeNumber()), diff --git a/src/gui/xic_view/xicworkerthread.h b/src/gui/xic_view/xicworkerthread.h index 4285d8406e156c94ea97d436b3446e491355ce62..3b699a7f2eb4fcd557d605e12e1fc8a3144bdf97 100644 --- a/src/gui/xic_view/xicworkerthread.h +++ b/src/gui/xic_view/xicworkerthread.h @@ -43,7 +43,8 @@ class XicWorkerThread : public QObject XicWorkerThread(XicBox *parent); virtual ~XicWorkerThread(); public slots: - void doXicLoad(MsRunSp p_msrun, std::vector<pappso::pappso_double> mz_list, + void doXicLoad(MsRunSp p_msrun, + std::vector<pappso::pappso_double> mz_list, pappso::PrecisionPtr precision, pappso::XicExtractMethod method); void doComputeIsotopeMassList(pappso::PeptideSp peptide_sp, diff --git a/src/input/condorqxmlsaxhandler.cpp b/src/input/condorqxmlsaxhandler.cpp index 0b7081d3794435b5d0297cdc249768636bedc0be..726e9b8b6f14625cc9aa756261bc6763cfb2eb6b 100644 --- a/src/input/condorqxmlsaxhandler.cpp +++ b/src/input/condorqxmlsaxhandler.cpp @@ -72,16 +72,18 @@ CondorQxmlSaxHandler::startElement(const QString &namespaceURI, } catch(pappso::PappsoException exception_pappso) { - _errorStr = QObject::tr("ERROR in CondorQxmlSaxHandler::startElement tag " - "%1, PAPPSO exception:\n%2") + _errorStr = QObject::tr( + "ERROR in CondorQxmlSaxHandler::startElement tag " + "%1, PAPPSO exception:\n%2") .arg(qName) .arg(exception_pappso.qwhat()); return false; } catch(std::exception exception_std) { - _errorStr = QObject::tr("ERROR in CondorQxmlSaxHandler::startElement tag " - "%1, std exception:\n%2") + _errorStr = QObject::tr( + "ERROR in CondorQxmlSaxHandler::startElement tag " + "%1, std exception:\n%2") .arg(qName) .arg(exception_std.what()); return false; @@ -91,7 +93,8 @@ CondorQxmlSaxHandler::startElement(const QString &namespaceURI, bool CondorQxmlSaxHandler::endElement(const QString &namespaceURI, - const QString &localName, const QString &qName) + const QString &localName, + const QString &qName) { bool is_ok = true; @@ -118,16 +121,18 @@ CondorQxmlSaxHandler::endElement(const QString &namespaceURI, } catch(pappso::PappsoException exception_pappso) { - _errorStr = QObject::tr("ERROR in CondorQxmlSaxHandler::endElement tag " - "%1, PAPPSO exception:\n%2") + _errorStr = QObject::tr( + "ERROR in CondorQxmlSaxHandler::endElement tag " + "%1, PAPPSO exception:\n%2") .arg(qName) .arg(exception_pappso.qwhat()); return false; } catch(std::exception exception_std) { - _errorStr = QObject::tr("ERROR in CondorQxmlSaxHandler::endElement tag " - "%1, std exception:\n%2") + _errorStr = QObject::tr( + "ERROR in CondorQxmlSaxHandler::endElement tag " + "%1, std exception:\n%2") .arg(qName) .arg(exception_std.what()); return false; @@ -143,8 +148,9 @@ CondorQxmlSaxHandler::endElement(const QString &namespaceURI, bool CondorQxmlSaxHandler::error(const QXmlParseException &exception) { - _errorStr = QObject::tr("Parse error at line %1, column %2 :\n" - "%3") + _errorStr = QObject::tr( + "Parse error at line %1, column %2 :\n" + "%3") .arg(exception.lineNumber()) .arg(exception.columnNumber()) .arg(exception.message()); @@ -156,8 +162,9 @@ CondorQxmlSaxHandler::error(const QXmlParseException &exception) bool CondorQxmlSaxHandler::fatalError(const QXmlParseException &exception) { - _errorStr = QObject::tr("Parse error at line %1, column %2 :\n" - "%3") + _errorStr = QObject::tr( + "Parse error at line %1, column %2 :\n" + "%3") .arg(exception.lineNumber()) .arg(exception.columnNumber()) .arg(exception.message()); diff --git a/src/input/condorqxmlsaxhandler.h b/src/input/condorqxmlsaxhandler.h index 4fd269c619fbc50a0cead5d997c9ec4688816fe6..9b2e05b9f18e60373a3e25cb0175874c06b02778 100644 --- a/src/input/condorqxmlsaxhandler.h +++ b/src/input/condorqxmlsaxhandler.h @@ -55,10 +55,13 @@ class CondorQxmlSaxHandler : public QXmlDefaultHandler CondorQxmlSaxHandler(TandemCondorProcess *tandem_condor_process); ~CondorQxmlSaxHandler(); - bool startElement(const QString &namespaceURI, const QString &localName, - const QString &qName, const QXmlAttributes &attributes); + bool startElement(const QString &namespaceURI, + const QString &localName, + const QString &qName, + const QXmlAttributes &attributes); - bool endElement(const QString &namespaceURI, const QString &localName, + bool endElement(const QString &namespaceURI, + const QString &localName, const QString &qName); bool startDocument(); diff --git a/src/input/identificationpwizreader.cpp b/src/input/identificationpwizreader.cpp index 9cc1dafc62a95eb59c73597dedcf2e8368332edf..73b854753f830fa82c465ba0b2eca6d5dd475f66 100644 --- a/src/input/identificationpwizreader.cpp +++ b/src/input/identificationpwizreader.cpp @@ -252,7 +252,8 @@ getQVariantDoubleParam(pwiz::data::ParamContainer *item, pwiz::cv::CVID param) void IdentificationPwizReader::read( - IdentificationDataSource *p_identification_data_source, Project *p_project, + IdentificationDataSource *p_identification_data_source, + Project *p_project, IdentificationGroup *p_identification_group) { qDebug() << "IdentificationPwizReader::read begin"; diff --git a/src/input/identificationpwizreader.h b/src/input/identificationpwizreader.h index 4738d65f668345c032277e8bbcc3090786ad65f6..bba10d615219fb3114d2c5291b86848c9a54f492 100644 --- a/src/input/identificationpwizreader.h +++ b/src/input/identificationpwizreader.h @@ -42,10 +42,10 @@ namespace pwiz { - namespace identdata - { - class IdentDataFile; - } +namespace identdata +{ +class IdentDataFile; +} } // namespace pwiz class IdentificationPwizReader @@ -57,7 +57,8 @@ class IdentificationPwizReader IdentificationEngine getIdentificationEngine() const; void read(IdentificationDataSource *p_identification_data_source, - Project *p_project, IdentificationGroup *p_identification_group); + Project *p_project, + IdentificationGroup *p_identification_group); private: IdentificationEngine getIdentificationEngine(const QString &xml_id) const; diff --git a/src/input/pepxmlsaxhandler.cpp b/src/input/pepxmlsaxhandler.cpp index bdc252be19be465fc45eb1486277202beef524b0..4d3b8432864d23b7ce4d85eac18f64b3d6e7eaa6 100644 --- a/src/input/pepxmlsaxhandler.cpp +++ b/src/input/pepxmlsaxhandler.cpp @@ -332,7 +332,7 @@ PepXmlSaxHandler::startElement_spectrum_query(QXmlAttributes attributes) //<alternative_protein protein="sp|P46784|RS10B_YEAST" protein_descr="40S // ribosomal protein S10-B OS=Saccharomyces cerevisiae (strain ATCC 204508 -// \ +// \ //S288c) GN=RPS10B PE=1 SV=1" num_tol_term="2" peptide_prev_aa="K" // peptide_next_aa="N"/> bool diff --git a/src/input/pepxmlsaxhandler.h b/src/input/pepxmlsaxhandler.h index 8856408c83d1c7cec5d1c68b4ff8b009174f1f18..ac42d0184e479eb90c0d39c4e73382a084704aeb 100644 --- a/src/input/pepxmlsaxhandler.h +++ b/src/input/pepxmlsaxhandler.h @@ -46,10 +46,13 @@ class PepXmlSaxHandler : public QXmlDefaultHandler IdentificationDataSource *p_identification_data_source); ~PepXmlSaxHandler(); - bool startElement(const QString &namespaceURI, const QString &localName, - const QString &qName, const QXmlAttributes &attributes); + bool startElement(const QString &namespaceURI, + const QString &localName, + const QString &qName, + const QXmlAttributes &attributes); - bool endElement(const QString &namespaceURI, const QString &localName, + bool endElement(const QString &namespaceURI, + const QString &localName, const QString &qName); bool startDocument(); diff --git a/src/input/xpipsaxhandler.h b/src/input/xpipsaxhandler.h index 4a4731c27345816c5e28809e3bdc743ed7cf3bc4..cc692ecd2c630c279acf064c25f988057fba1a26 100644 --- a/src/input/xpipsaxhandler.h +++ b/src/input/xpipsaxhandler.h @@ -39,10 +39,13 @@ class XpipSaxHandler : public QXmlDefaultHandler XpipSaxHandler(WorkMonitorInterface *p_monitor, Project *p_project); ~XpipSaxHandler(); - bool startElement(const QString &namespaceURI, const QString &localName, - const QString &qName, const QXmlAttributes &attributes); + bool startElement(const QString &namespaceURI, + const QString &localName, + const QString &qName, + const QXmlAttributes &attributes); - bool endElement(const QString &namespaceURI, const QString &localName, + bool endElement(const QString &namespaceURI, + const QString &localName, const QString &qName); bool startDocument(); diff --git a/src/input/xtpxpipsaxhandler.cpp b/src/input/xtpxpipsaxhandler.cpp index 3f44fcef2dd102ad595cfe26abd1f5d04793ada0..a755348deedbe1d8d5664da8617ddb5a3f5422b8 100644 --- a/src/input/xtpxpipsaxhandler.cpp +++ b/src/input/xtpxpipsaxhandler.cpp @@ -589,8 +589,8 @@ XtpXpipSaxHandler::startElement_msrun(QXmlAttributes attributes) bool XtpXpipSaxHandler::startElement_alignmentGroup(QXmlAttributes attributes) { - msp_alignment_group = std::make_shared<MsRunAlignmentGroup>(_p_project, - attributes.value("name").simplified()); + msp_alignment_group = std::make_shared<MsRunAlignmentGroup>( + _p_project, attributes.value("name").simplified()); _p_project->addMsRunAlignmentGroupToList(msp_alignment_group); QString reference_id = attributes.value("reference").simplified(); if(reference_id != "") diff --git a/src/output/masschroqprm.h b/src/output/masschroqprm.h index 0ad73cbb6dfa193969da4ac9d650a695b73f32ad..754b94379a704ec9e358f8254d433b11f5fc95c6 100644 --- a/src/output/masschroqprm.h +++ b/src/output/masschroqprm.h @@ -54,4 +54,3 @@ class MassChroqPrm ProjectSp _sp_project; IdentificationGroup *_p_identification_group; }; - diff --git a/src/output/mcqr/mcqrscpeptide.cpp b/src/output/mcqr/mcqrscpeptide.cpp index a855c9dd6f5899ce94e8ce837c2f59a9d98b8978..8d9bca9bd6982f71d1b9ad9a355925b4c3477d0d 100644 --- a/src/output/mcqr/mcqrscpeptide.cpp +++ b/src/output/mcqr/mcqrscpeptide.cpp @@ -98,7 +98,8 @@ McqRscPeptide::writeIdentificationGroup(IdentificationGroup *p_ident) std::vector<const ProteinMatch *> protein_match_list = group_pair.second.get()->getProteinMatchList(); - std::sort(protein_match_list.begin(), protein_match_list.end(), + std::sort(protein_match_list.begin(), + protein_match_list.end(), [](const ProteinMatch *a, const ProteinMatch *b) { return a->getGrpProteinSp().get()->getSubGroupNumber() < b->getGrpProteinSp().get()->getSubGroupNumber(); @@ -125,8 +126,10 @@ McqRscPeptide::writeIdentificationGroup(IdentificationGroup *p_ident) std::vector<PeptideMatch> peptide_match_in_msrun = protein_match->getPeptideMatchList(validation_state, msrun_sp.get()); - writePeptidesInMsrun(protein_match, msrun_sp.get(), - peptide_match_in_msrun, count_scan_zero); + writePeptidesInMsrun(protein_match, + msrun_sp.get(), + peptide_match_in_msrun, + count_scan_zero); } } } @@ -136,7 +139,8 @@ McqRscPeptide::writeIdentificationGroup(IdentificationGroup *p_ident) void McqRscPeptide::writePeptidesInMsrun( - const ProteinMatch *p_protein_match, const MsRun *p_msrun, + const ProteinMatch *p_protein_match, + const MsRun *p_msrun, const std::vector<PeptideMatch> &peptide_match_in_msrun, const std::map<ScPeptideLabel, std::size_t> &count_scan_zero) { @@ -194,7 +198,8 @@ McqRscPeptide::writePeptidesInMsrun( (unsigned int)p_protein_match->getGroupingGroupSp() .get() ->countSpecificSequenceLi(p_protein_match, - ValidationState::grouped, p_msrun, + ValidationState::grouped, + p_msrun, pair_count.first._p_label)); } qDebug() << "McqRscPeptide::writePeptidesInMsrun end"; diff --git a/src/output/mcqr/mcqrscpeptide.h b/src/output/mcqr/mcqrscpeptide.h index 977a478fe17f0256b2e8449a19482b9a17b26dc9..76984f839e94d385041253fa6e4a3df75f511f3c 100644 --- a/src/output/mcqr/mcqrscpeptide.h +++ b/src/output/mcqr/mcqrscpeptide.h @@ -55,7 +55,8 @@ class McqRscPeptide void writeIdentificationGroup(IdentificationGroup *p_ident); void writeHeaders(IdentificationGroup *p_ident); void writePeptidesInMsrun( - const ProteinMatch *p_protein_match, const MsRun *p_msrun, + const ProteinMatch *p_protein_match, + const MsRun *p_msrun, const std::vector<PeptideMatch> &peptide_match_in_msrun, const std::map<ScPeptideLabel, std::size_t> &count_scan_zero); diff --git a/src/output/mcqr/mcqrscprotein.cpp b/src/output/mcqr/mcqrscprotein.cpp index b77b4830c2fe473ac7351abeb13bdd746bd55c36..c6c34ce3c8212c6d5707f275f5364d16755e58ce 100644 --- a/src/output/mcqr/mcqrscprotein.cpp +++ b/src/output/mcqr/mcqrscprotein.cpp @@ -87,7 +87,8 @@ McqRscProtein::writeIdentificationGroup(IdentificationGroup *p_ident) std::vector<const ProteinMatch *> protein_match_list = group_pair.second.get()->getProteinMatchList(); - std::sort(protein_match_list.begin(), protein_match_list.end(), + std::sort(protein_match_list.begin(), + protein_match_list.end(), [](const ProteinMatch *a, const ProteinMatch *b) { return a->getGrpProteinSp().get()->getSubGroupNumber() < b->getGrpProteinSp().get()->getSubGroupNumber(); diff --git a/src/output/mcqrspectralcount.cpp b/src/output/mcqrspectralcount.cpp index 60c8e45c0f532e9d1be664f40c39d4ab069fb5a2..77fc580f0b586e5dfebd452ecfbdfc5930bb8403 100644 --- a/src/output/mcqrspectralcount.cpp +++ b/src/output/mcqrspectralcount.cpp @@ -102,7 +102,8 @@ McqrSpectralCount::writeIdentificationGroup(IdentificationGroup *p_ident) std::vector<const ProteinMatch *> protein_match_list = group_pair.second.get()->getProteinMatchList(); - std::sort(protein_match_list.begin(), protein_match_list.end(), + std::sort(protein_match_list.begin(), + protein_match_list.end(), [](const ProteinMatch *a, const ProteinMatch *b) { return a->getGrpProteinSp().get()->getSubGroupNumber() < b->getGrpProteinSp().get()->getSubGroupNumber(); @@ -139,15 +140,21 @@ McqrSpectralCount::writeOneProtein(const GroupingGroup *p_group, if(_label_list.size() == 0) { - writeOneProteinLabel(p_grp_protein, msrun_sp.get(), nullptr, - p_protein, p_protein_match); + writeOneProteinLabel(p_grp_protein, + msrun_sp.get(), + nullptr, + p_protein, + p_protein_match); } else { for(auto &p_label : _label_list) { - writeOneProteinLabel(p_grp_protein, msrun_sp.get(), p_label, - p_protein, p_protein_match); + writeOneProteinLabel(p_grp_protein, + msrun_sp.get(), + p_label, + p_protein, + p_protein_match); } } } @@ -194,9 +201,9 @@ McqrSpectralCount::writeOneProteinLabel(const pappso::GrpProtein *p_grp_protein, _p_writer->writeCell(p_protein_match->countSampleScan( ValidationState::grouped, p_msrun, p_label)); - _p_writer->writeCell((unsigned int)p_protein_match->getGroupingGroupSp() - .get() - ->countSpecificSampleScan(p_protein_match, - ValidationState::grouped, - p_msrun, p_label)); + _p_writer->writeCell( + (unsigned int)p_protein_match->getGroupingGroupSp() + .get() + ->countSpecificSampleScan( + p_protein_match, ValidationState::grouped, p_msrun, p_label)); } diff --git a/src/output/mcqrspectralcount.h b/src/output/mcqrspectralcount.h index bf26cfd836bb8eb8bd5ebb37f08c5ad7b4c5fc73..d6a401335eb95da8519e77c5d3aa90e1f4de6b3d 100644 --- a/src/output/mcqrspectralcount.h +++ b/src/output/mcqrspectralcount.h @@ -47,7 +47,8 @@ class McqrSpectralCount void writeOneProtein(const GroupingGroup *p_group, const ProteinMatch *p_protein_match); void writeOneProteinLabel(const pappso::GrpProtein *p_grp_protein, - const MsRun *p_msrun, const Label *p_label, + const MsRun *p_msrun, + const Label *p_label, const ProteinXtp *p_protein, const ProteinMatch *p_protein_match); diff --git a/src/output/ods/comparbasesheet.cpp b/src/output/ods/comparbasesheet.cpp index 88e1115b2fe45d9f613207a81d6ab34f595388f2..3c7bfaa5533bc635701407f3559d173a051862d2 100644 --- a/src/output/ods/comparbasesheet.cpp +++ b/src/output/ods/comparbasesheet.cpp @@ -164,8 +164,8 @@ ComparBaseSheet::writeProteinMatch(const ProteinMatch *p_protein_match) { if(_label_list.size() == 0) { - writeComparValue(p_protein_match, ValidationState::validAndChecked, - msrun_sp.get()); + writeComparValue( + p_protein_match, ValidationState::validAndChecked, msrun_sp.get()); if(_first_cell_coordinate.isEmpty()) { _first_cell_coordinate = _p_writer->getOdsCellCoordinate(); @@ -176,7 +176,8 @@ ComparBaseSheet::writeProteinMatch(const ProteinMatch *p_protein_match) for(const Label *p_label : _label_list) { writeComparValue(p_protein_match, - ValidationState::validAndChecked, msrun_sp.get(), + ValidationState::validAndChecked, + msrun_sp.get(), p_label); if(_first_cell_coordinate.isEmpty()) { @@ -211,7 +212,8 @@ ComparBaseSheet::writeIdentificationGroup(IdentificationGroup *p_ident) } std::sort( - protein_match_list.begin(), protein_match_list.end(), + protein_match_list.begin(), + protein_match_list.end(), [](const ProteinMatch *a, const ProteinMatch *b) { unsigned int agroup = a->getGrpProteinSp().get()->getGroupNumber(); unsigned int asubgroup = a->getGrpProteinSp().get()->getSubGroupNumber(); diff --git a/src/output/ods/comparbasesheet.h b/src/output/ods/comparbasesheet.h index 4b85ab7d9fc2fb5a9a8468c4045902cf362d549e..c5871f865a1172fcbd0e8cdaea2f9e34a2085d0c 100644 --- a/src/output/ods/comparbasesheet.h +++ b/src/output/ods/comparbasesheet.h @@ -39,7 +39,8 @@ class ComparBaseSheet { public: - ComparBaseSheet(OdsExport *p_ods_export, CalcWriterInterface *p_writer, + ComparBaseSheet(OdsExport *p_ods_export, + CalcWriterInterface *p_writer, const Project *p_project); private: @@ -51,7 +52,8 @@ class ComparBaseSheet protected: virtual void writeComparValue(const ProteinMatch *p_protein_match, - ValidationState state, const MsRun *p_msrun, + ValidationState state, + const MsRun *p_msrun, const Label *p_label = nullptr) = 0; void writeProteinMatch(const ProteinMatch *p_protein_match); diff --git a/src/output/ods/comparspecificspectrasheet.cpp b/src/output/ods/comparspecificspectrasheet.cpp index 5ad6c4fed7af0d0536b79ce0d2d255916fdc3cc3..20e6923abcd678101b7fad94f5de2f67f3f126c3 100644 --- a/src/output/ods/comparspecificspectrasheet.cpp +++ b/src/output/ods/comparspecificspectrasheet.cpp @@ -32,7 +32,8 @@ ComparSpecificSpectraSheet::ComparSpecificSpectraSheet( - OdsExport *p_ods_export, CalcWriterInterface *p_writer, + OdsExport *p_ods_export, + CalcWriterInterface *p_writer, const Project *p_project) : ComparBaseSheet(p_ods_export, p_writer, p_project) { @@ -42,8 +43,10 @@ ComparSpecificSpectraSheet::ComparSpecificSpectraSheet( void ComparSpecificSpectraSheet::writeComparValue( - const ProteinMatch *p_protein_match, ValidationState state, - const MsRun *p_msrun, const Label *p_label) + const ProteinMatch *p_protein_match, + ValidationState state, + const MsRun *p_msrun, + const Label *p_label) { qDebug() << "ComparSpecificSpectraSheet::writeComparValue begin"; _p_writer->writeCell( @@ -55,7 +58,8 @@ ComparSpecificSpectraSheet::writeComparValue( ComparSpecificSequenceSheet::ComparSpecificSequenceSheet( - OdsExport *p_ods_export, CalcWriterInterface *p_writer, + OdsExport *p_ods_export, + CalcWriterInterface *p_writer, const Project *p_project) : ComparBaseSheet(p_ods_export, p_writer, p_project) { @@ -64,8 +68,10 @@ ComparSpecificSequenceSheet::ComparSpecificSequenceSheet( void ComparSpecificSequenceSheet::writeComparValue( - const ProteinMatch *p_protein_match, ValidationState state, - const MsRun *p_msrun, const Label *p_label) + const ProteinMatch *p_protein_match, + ValidationState state, + const MsRun *p_msrun, + const Label *p_label) { qDebug() << "ComparSpecificSequenceSheet::writeComparValue begin"; _p_writer->writeCell( diff --git a/src/output/ods/comparspecificspectrasheet.h b/src/output/ods/comparspecificspectrasheet.h index 90398835876a79e96aff937a41e534b01402e724..e677f28f97ffcfd02bff8684b364b2979082220e 100644 --- a/src/output/ods/comparspecificspectrasheet.h +++ b/src/output/ods/comparspecificspectrasheet.h @@ -41,7 +41,8 @@ class ComparSpecificSpectraSheet : public ComparBaseSheet protected: virtual void writeComparValue(const ProteinMatch *p_protein_match, - ValidationState state, const MsRun *p_msrun, + ValidationState state, + const MsRun *p_msrun, const Label *p_label = nullptr) override; }; @@ -54,7 +55,8 @@ class ComparSpecificSequenceSheet : public ComparBaseSheet protected: virtual void writeComparValue(const ProteinMatch *p_protein_match, - ValidationState state, const MsRun *p_msrun, + ValidationState state, + const MsRun *p_msrun, const Label *p_label = nullptr) override; }; diff --git a/src/output/ods/comparspectrabypeptide.cpp b/src/output/ods/comparspectrabypeptide.cpp index 1649ee15b700fb22a73b112feef2168f867b67bc..2898bbe1dc4ebae75ac3dd548363f8ab80b76e14 100644 --- a/src/output/ods/comparspectrabypeptide.cpp +++ b/src/output/ods/comparspectrabypeptide.cpp @@ -132,7 +132,8 @@ ComparSpectraByPeptide::writeIdentificationGroup(IdentificationGroup *p_ident) std::vector<const PeptideEvidence *> peptide_evidence_list = group_pair.second.get()->getPeptideEvidenceList(); - std::sort(peptide_evidence_list.begin(), peptide_evidence_list.end(), + std::sort(peptide_evidence_list.begin(), + peptide_evidence_list.end(), [](const PeptideEvidence *a, const PeptideEvidence *b) { return a->getGrpPeptideSp().get()->getRank() < b->getGrpPeptideSp().get()->getRank(); @@ -198,8 +199,8 @@ ComparSpectraByPeptide::writeIdentificationGroup(IdentificationGroup *p_ident) if(p_best_peptide_evidence != nullptr) { - writeBestPeptideEvidence(group_pair.second.get(), - p_best_peptide_evidence, sample_scan_list); + writeBestPeptideEvidence( + group_pair.second.get(), p_best_peptide_evidence, sample_scan_list); sample_scan_list.clear(); } } @@ -221,7 +222,8 @@ ComparSpectraByPeptide::writeIdentificationGroup(IdentificationGroup *p_ident) void ComparSpectraByPeptide::writeBestPeptideEvidence( - const GroupingGroup *p_group, const PeptideEvidence *p_peptide_evidence, + const GroupingGroup *p_group, + const PeptideEvidence *p_peptide_evidence, const std::map<QString, std::vector<size_t>> &sample_scan_list) { @@ -255,8 +257,8 @@ ComparSpectraByPeptide::writeBestPeptideEvidence( { if(_label_list.size() == 0) { - writeComparValue(sample_scan_list, ValidationState::validAndChecked, - msrun_sp.get()); + writeComparValue( + sample_scan_list, ValidationState::validAndChecked, msrun_sp.get()); if(_first_cell_coordinate.isEmpty()) { _first_cell_coordinate = _p_writer->getOdsCellCoordinate(); @@ -267,7 +269,8 @@ ComparSpectraByPeptide::writeBestPeptideEvidence( for(const Label *p_label : _label_list) { writeComparValue(sample_scan_list, - ValidationState::validAndChecked, msrun_sp.get(), + ValidationState::validAndChecked, + msrun_sp.get(), p_label); if(_first_cell_coordinate.isEmpty()) { @@ -282,7 +285,9 @@ ComparSpectraByPeptide::writeBestPeptideEvidence( void ComparSpectraByPeptide::writeComparValue( const std::map<QString, std::vector<size_t>> &sample_scan_list, - ValidationState state, const MsRun *p_msrun, const Label *p_label) + ValidationState state, + const MsRun *p_msrun, + const Label *p_label) { /* std::sort(sample_scan_list.begin(), sample_scan_list.end()); diff --git a/src/output/ods/comparspectrabypeptide.h b/src/output/ods/comparspectrabypeptide.h index 97436247ff6f6ccffd05737e6d985cae666cc8f1..a566384d31c783fc0b29ce3dd4a9c0d3a23d446a 100644 --- a/src/output/ods/comparspectrabypeptide.h +++ b/src/output/ods/comparspectrabypeptide.h @@ -50,15 +50,18 @@ class ComparSpectraByPeptide void writeIdentificationGroup(IdentificationGroup *p_ident); void writeHeaders(IdentificationGroup *p_ident); void writeBestPeptideEvidence( - const GroupingGroup *p_group, const PeptideEvidence *p_peptide_evidence, + const GroupingGroup *p_group, + const PeptideEvidence *p_peptide_evidence, const std::map<QString, std::vector<size_t>> &sample_scan_list); void writeComparValue( const std::map<QString, std::vector<size_t>> &sample_scan_list, - ValidationState state, const MsRun *p_msrun, + ValidationState state, + const MsRun *p_msrun, const Label *p_label = nullptr); public: - ComparSpectraByPeptide(OdsExport *p_ods_export, CalcWriterInterface *p_writer, + ComparSpectraByPeptide(OdsExport *p_ods_export, + CalcWriterInterface *p_writer, const Project *p_project); void writeSheet(); }; diff --git a/src/output/ods/comparspectrasheet.cpp b/src/output/ods/comparspectrasheet.cpp index 184ee49aa09b619373c9c131235be981ba6236a9..b9ee4cc32c6eb1f6d0e503358be87e0935e9f503 100644 --- a/src/output/ods/comparspectrasheet.cpp +++ b/src/output/ods/comparspectrasheet.cpp @@ -46,7 +46,8 @@ ComparSpectraSheet::ComparSpectraSheet(OdsExport *p_ods_export, void ComparSpectraSheet::writeComparValue(const ProteinMatch *p_protein_match, ValidationState state, - const MsRun *p_msrun, const Label *p_label) + const MsRun *p_msrun, + const Label *p_label) { qDebug() << "ComparSpectraSheet::writeComparValue begin"; _p_writer->writeCell( @@ -85,7 +86,8 @@ ComparPaiSheet::ComparPaiSheet(OdsExport *p_ods_export, void ComparPaiSheet::writeComparValue(const ProteinMatch *p_protein_match, - ValidationState state, const MsRun *p_msrun, + ValidationState state, + const MsRun *p_msrun, const Label *p_label) { qDebug() << "ComparPaiSheet::writeComparValue begin"; @@ -103,7 +105,8 @@ ComparEmpaiSheet::ComparEmpaiSheet(OdsExport *p_ods_export, void ComparEmpaiSheet::writeComparValue(const ProteinMatch *p_protein_match, - ValidationState state, const MsRun *p_msrun, + ValidationState state, + const MsRun *p_msrun, const Label *p_label) { qDebug() << "ComparEmpaiSheet::writeComparValue begin"; @@ -121,7 +124,8 @@ ComparNsafSheet::ComparNsafSheet(OdsExport *p_ods_export, void ComparNsafSheet::writeComparValue(const ProteinMatch *p_protein_match, - ValidationState state, const MsRun *p_msrun, + ValidationState state, + const MsRun *p_msrun, const Label *p_label) { qDebug() << "ComparNsafSheet::writeComparValue begin"; diff --git a/src/output/ods/comparspectrasheet.h b/src/output/ods/comparspectrasheet.h index 04b0df804e5d026985c24b9eab7e3b7372fac212..d129f71f728bd408dc887d27843dbf7720014a28 100644 --- a/src/output/ods/comparspectrasheet.h +++ b/src/output/ods/comparspectrasheet.h @@ -36,12 +36,14 @@ class ComparSpectraSheet : public ComparBaseSheet { public: - ComparSpectraSheet(OdsExport *p_ods_export, CalcWriterInterface *p_writer, + ComparSpectraSheet(OdsExport *p_ods_export, + CalcWriterInterface *p_writer, const Project *p_project); protected: virtual void writeComparValue(const ProteinMatch *p_protein_match, - ValidationState state, const MsRun *p_msrun, + ValidationState state, + const MsRun *p_msrun, const Label *p_label = nullptr) override; }; @@ -49,48 +51,56 @@ class ComparSpectraSheet : public ComparBaseSheet class ComparSequenceSheet : public ComparBaseSheet { public: - ComparSequenceSheet(OdsExport *p_ods_export, CalcWriterInterface *p_writer, + ComparSequenceSheet(OdsExport *p_ods_export, + CalcWriterInterface *p_writer, const Project *p_project); protected: virtual void writeComparValue(const ProteinMatch *p_protein_match, - ValidationState state, const MsRun *p_msrun, + ValidationState state, + const MsRun *p_msrun, const Label *p_label = nullptr) override; }; class ComparPaiSheet : public ComparBaseSheet { public: - ComparPaiSheet(OdsExport *p_ods_export, CalcWriterInterface *p_writer, + ComparPaiSheet(OdsExport *p_ods_export, + CalcWriterInterface *p_writer, const Project *p_project); protected: virtual void writeComparValue(const ProteinMatch *p_protein_match, - ValidationState state, const MsRun *p_msrun, + ValidationState state, + const MsRun *p_msrun, const Label *p_label = nullptr) override; }; class ComparEmpaiSheet : public ComparBaseSheet { public: - ComparEmpaiSheet(OdsExport *p_ods_export, CalcWriterInterface *p_writer, + ComparEmpaiSheet(OdsExport *p_ods_export, + CalcWriterInterface *p_writer, const Project *p_project); protected: virtual void writeComparValue(const ProteinMatch *p_protein_match, - ValidationState state, const MsRun *p_msrun, + ValidationState state, + const MsRun *p_msrun, const Label *p_label = nullptr) override; }; class ComparNsafSheet : public ComparBaseSheet { public: - ComparNsafSheet(OdsExport *p_ods_export, CalcWriterInterface *p_writer, + ComparNsafSheet(OdsExport *p_ods_export, + CalcWriterInterface *p_writer, const Project *p_project); protected: virtual void writeComparValue(const ProteinMatch *p_protein_match, - ValidationState state, const MsRun *p_msrun, + ValidationState state, + const MsRun *p_msrun, const Label *p_label = nullptr) override; private: diff --git a/src/output/ods/groupingsheet.h b/src/output/ods/groupingsheet.h index 9202bc4fd7b64a0bcebd3537502c0ea891849218..ec253be645b5bcc650fd78ef45d4639903479aa3 100644 --- a/src/output/ods/groupingsheet.h +++ b/src/output/ods/groupingsheet.h @@ -38,7 +38,8 @@ class GroupingSheet { public: - GroupingSheet(OdsExport *p_ods_export, CalcWriterInterface *p_writer, + GroupingSheet(OdsExport *p_ods_export, + CalcWriterInterface *p_writer, const Project *p_project); private: diff --git a/src/output/ods/infosheet.cpp b/src/output/ods/infosheet.cpp index 364bacfbaea13c6a3419de8d84fe951274c3614a..4b6699e6fc1d5d08631611dd0c6de70c89b471c7 100644 --- a/src/output/ods/infosheet.cpp +++ b/src/output/ods/infosheet.cpp @@ -34,7 +34,8 @@ #include <QSettings> -InfoSheet::InfoSheet(OdsExport *p_ods_export, CalcWriterInterface *p_writer, +InfoSheet::InfoSheet(OdsExport *p_ods_export, + CalcWriterInterface *p_writer, const Project *p_project) : _p_project(p_project) { @@ -129,8 +130,9 @@ InfoSheet::InfoSheet(OdsExport *p_ods_export, CalcWriterInterface *p_writer, if(settings.value("export_ods/groups", "true").toBool()) { p_writer->writeCell("groups"); - p_writer->writeCell("simple statistics on the current grouping " - "experiment (numbers of groups, subgroups...)"); + p_writer->writeCell( + "simple statistics on the current grouping " + "experiment (numbers of groups, subgroups...)"); p_writer->writeLine(); } @@ -144,26 +146,29 @@ InfoSheet::InfoSheet(OdsExport *p_ods_export, CalcWriterInterface *p_writer, if(settings.value("export_ods/peptides", "true").toBool()) { p_writer->writeCell("peptides"); - p_writer->writeCell("list of peptides used by the grouping algorithm. " - "Beware : peptides are intended as unique pairs of " - "sequence+mass, given that Leucine and Isoleucine as " - "the same mass, all Leucines are considered as " - "Isoleucines"); + p_writer->writeCell( + "list of peptides used by the grouping algorithm. " + "Beware : peptides are intended as unique pairs of " + "sequence+mass, given that Leucine and Isoleucine as " + "the same mass, all Leucines are considered as " + "Isoleucines"); p_writer->writeLine(); } if(settings.value("export_ods/spectra", "true").toBool()) { p_writer->writeCell("spectra"); - p_writer->writeCell("list of all validated and checked spectrum match. " - "Only the best assigned peptide (best Evalue) is " - "reported "); + p_writer->writeCell( + "list of all validated and checked spectrum match. " + "Only the best assigned peptide (best Evalue) is " + "reported "); p_writer->writeLine(); } if(settings.value("export_ods/peptidepos", "true").toBool()) { p_writer->writeCell("peptide pos"); - p_writer->writeCell("list of all *real* peptides identified on their " - "proteins, with their position on the sequence."); + p_writer->writeCell( + "list of all *real* peptides identified on their " + "proteins, with their position on the sequence."); p_writer->writeLine(); } } diff --git a/src/output/ods/peptidesheet.cpp b/src/output/ods/peptidesheet.cpp index 8e97e737a2595d7b615f4c63f3d716ff3c37e5a1..c05710d44f9ada89362610a91384a4686565dfc7 100644 --- a/src/output/ods/peptidesheet.cpp +++ b/src/output/ods/peptidesheet.cpp @@ -101,7 +101,8 @@ PeptideSheet::writeIdentificationGroup(IdentificationGroup *p_ident) std::vector<const PeptideEvidence *> peptide_evidence_list = group_pair.second.get()->getPeptideEvidenceList(); - std::sort(peptide_evidence_list.begin(), peptide_evidence_list.end(), + std::sort(peptide_evidence_list.begin(), + peptide_evidence_list.end(), [](const PeptideEvidence *a, const PeptideEvidence *b) { return a->getGrpPeptideSp().get()->getRank() < b->getGrpPeptideSp().get()->getRank(); diff --git a/src/output/ods/peptidesheet.h b/src/output/ods/peptidesheet.h index 7db49c459755b1ee2c01ea27459fa19d643ae125..1f64c4bed11563c7ab16aef1439b7db6dd8881e8 100644 --- a/src/output/ods/peptidesheet.h +++ b/src/output/ods/peptidesheet.h @@ -39,7 +39,8 @@ class PeptideSheet { public: - PeptideSheet(OdsExport *p_ods_export, CalcWriterInterface *p_writer, + PeptideSheet(OdsExport *p_ods_export, + CalcWriterInterface *p_writer, const Project *p_project); private: diff --git a/src/output/ods/proteinsheet.h b/src/output/ods/proteinsheet.h index 660256246b3d3b08c939b7cf6d86dbcb038d87bc..a4e7347af2df7070152aa3a9e2fc2cab6f1b9d13 100644 --- a/src/output/ods/proteinsheet.h +++ b/src/output/ods/proteinsheet.h @@ -40,7 +40,8 @@ class ProteinSheet { public: - ProteinSheet(OdsExport *p_ods_export, CalcWriterInterface *p_writer, + ProteinSheet(OdsExport *p_ods_export, + CalcWriterInterface *p_writer, const Project *p_project); private: diff --git a/src/output/ods/ptm/ptmislandsheet.cpp b/src/output/ods/ptm/ptmislandsheet.cpp index 87e15abec5abe9bbeb629eccf985a0ec6653b33c..e6d9489f00d53cf0446998849266ad2ad59fba4f 100644 --- a/src/output/ods/ptm/ptmislandsheet.cpp +++ b/src/output/ods/ptm/ptmislandsheet.cpp @@ -133,7 +133,8 @@ PtmIslandSheet::writeIdentificationGroup(IdentificationGroup *p_ident) ptm_island_list.push_back(ptm_island_sp); } qDebug() << "PtmIslandSheet::writeIdentificationGroup sort"; - std::sort(ptm_island_list.begin(), ptm_island_list.end(), + std::sort(ptm_island_list.begin(), + ptm_island_list.end(), [](PtmIslandSp &a, PtmIslandSp &b) { return a.get()->getGroupingId() < b.get()->getGroupingId(); }); diff --git a/src/output/ods/ptm/ptmislandsheet.h b/src/output/ods/ptm/ptmislandsheet.h index b9e9071fd792d0f03e6d77670e9c0efd38cdf9f8..dcf46ad298193be515b7f28836a67feed59169d2 100644 --- a/src/output/ods/ptm/ptmislandsheet.h +++ b/src/output/ods/ptm/ptmislandsheet.h @@ -40,7 +40,8 @@ class PtmIslandSheet { public: - PtmIslandSheet(OdsExport *p_ods_export, CalcWriterInterface *p_writer, + PtmIslandSheet(OdsExport *p_ods_export, + CalcWriterInterface *p_writer, const Project *p_project); private: diff --git a/src/output/ods/ptm/ptmspectrasheet.h b/src/output/ods/ptm/ptmspectrasheet.h index 6b589c045e6ee0e065899167e3416511a66a29ed..4832ebeebbc7118d8ae38ac7e27e5f247435999c 100644 --- a/src/output/ods/ptm/ptmspectrasheet.h +++ b/src/output/ods/ptm/ptmspectrasheet.h @@ -40,12 +40,15 @@ class PtmSpectraSheet { public: - PtmSpectraSheet(OdsExport *p_ods_export, CalcWriterInterface *p_writer, + PtmSpectraSheet(OdsExport *p_ods_export, + CalcWriterInterface *p_writer, const Project *p_project); protected: - PtmSpectraSheet(OdsExport *p_ods_export, CalcWriterInterface *p_writer, - const Project *p_project, const QString &sheet_name); + PtmSpectraSheet(OdsExport *p_ods_export, + CalcWriterInterface *p_writer, + const Project *p_project, + const QString &sheet_name); virtual void writeIdentificationGroup(IdentificationGroup *p_ident); void writeHeaders(IdentificationGroup *p_ident); void writeBestPeptideEvidence( diff --git a/src/output/ods/qvaluessheet.cpp b/src/output/ods/qvaluessheet.cpp index 2a99efd5adc4d7a175fb76068589341e600649c8..6a5ba666ba1cd27c8697a07fcbfac4b7a9775809 100644 --- a/src/output/ods/qvaluessheet.cpp +++ b/src/output/ods/qvaluessheet.cpp @@ -40,9 +40,9 @@ QvaluesSheet::QvaluesSheet(OdsExport *p_ods_export, table_settings.setVerticalSplit(1); _p_writer->setCurrentOdsTableSettings(table_settings); - // writeHeaders(); + // writeHeaders(); ComputeQvalues qvalues(p_project); - + qvalues.writeDistributionsByEngines(_p_writer); } diff --git a/src/output/ods/samplesheet.cpp b/src/output/ods/samplesheet.cpp index 7f4f1570564cb42ef14f8fc4c1580e9ec0a0909f..48ad1acb5cd84ccdd0cf5a01e62421d0df0486cb 100644 --- a/src/output/ods/samplesheet.cpp +++ b/src/output/ods/samplesheet.cpp @@ -30,7 +30,8 @@ #include "samplesheet.h" -SampleSheet::SampleSheet(OdsExport *p_ods_export, CalcWriterInterface *p_writer, +SampleSheet::SampleSheet(OdsExport *p_ods_export, + CalcWriterInterface *p_writer, const Project *p_project) : _p_project(p_project) { @@ -118,16 +119,19 @@ SampleSheet::writeHeaders() "total number of MS level 3 during the MS run (from mz file)"); _p_writer->writeCell("Total MS3"); - _p_writer->setCellAnnotation("total ion current in MS level 1 spectra " - "during the MS run (from mz file)"); + _p_writer->setCellAnnotation( + "total ion current in MS level 1 spectra " + "during the MS run (from mz file)"); _p_writer->writeCell("TIC MS1"); - _p_writer->setCellAnnotation("total ion current in MS level 2 spectra " - "during the MS run (from mz file)"); + _p_writer->setCellAnnotation( + "total ion current in MS level 2 spectra " + "during the MS run (from mz file)"); _p_writer->writeCell("TIC MS2"); - _p_writer->setCellAnnotation("total ion current in MS level 3 spectra " - "during the MS run (from mz file)"); + _p_writer->setCellAnnotation( + "total ion current in MS level 3 spectra " + "during the MS run (from mz file)"); _p_writer->writeCell("TIC MS3"); } diff --git a/src/output/ods/samplesheet.h b/src/output/ods/samplesheet.h index 12677f5f2186c78196fda60434185f57c15b0f59..ce0181945787a6fc4c76e43b0eb449ed512128f6 100644 --- a/src/output/ods/samplesheet.h +++ b/src/output/ods/samplesheet.h @@ -38,7 +38,8 @@ class SampleSheet { public: - SampleSheet(OdsExport *p_ods_export, CalcWriterInterface *p_writer, + SampleSheet(OdsExport *p_ods_export, + CalcWriterInterface *p_writer, const Project *p_project); private: diff --git a/src/output/ods/spectrasheet.h b/src/output/ods/spectrasheet.h index 0f31554704bff491d64ebad8af14d8e2389537d0..09b5195eab93b4e12b387b158df8b9c93e481386 100644 --- a/src/output/ods/spectrasheet.h +++ b/src/output/ods/spectrasheet.h @@ -39,12 +39,15 @@ class SpectraSheet { public: - SpectraSheet(OdsExport *p_ods_export, CalcWriterInterface *p_writer, + SpectraSheet(OdsExport *p_ods_export, + CalcWriterInterface *p_writer, const Project *p_project); protected: - SpectraSheet(OdsExport *p_ods_export, CalcWriterInterface *p_writer, - const Project *p_project, const QString &sheet_name); + SpectraSheet(OdsExport *p_ods_export, + CalcWriterInterface *p_writer, + const Project *p_project, + const QString &sheet_name); virtual void writeIdentificationGroup(IdentificationGroup *p_ident); void writeHeaders(IdentificationGroup *p_ident); void writeBestPeptideEvidence(const GroupingGroup *p_group, @@ -56,4 +59,3 @@ class SpectraSheet const Project *_p_project; CalcWriterInterface *_p_writer; }; - diff --git a/src/utils/msrunstore.h b/src/utils/msrunstore.h index 4828d825eb73d93d2d31339c17390d2896db85b2..1e0003bc64898754b98bba594bc12efcc024026c 100644 --- a/src/utils/msrunstore.h +++ b/src/utils/msrunstore.h @@ -50,4 +50,3 @@ class MsRunStore private: std::vector<MsRunSp> _map_msrun; }; - diff --git a/src/utils/peptidestore.h b/src/utils/peptidestore.h index b815aed2895d048243cd8f5811c1586b1e45568b..8c8989253fce5ebb072e5daa90a9c18961503201 100644 --- a/src/utils/peptidestore.h +++ b/src/utils/peptidestore.h @@ -72,4 +72,3 @@ class PeptideStore std::unordered_map<std::size_t, PeptideXtpSp> _map_crc_peptide_list; std::set<pappso::AaModificationP> _modification_collection; }; - diff --git a/src/utils/utils.h b/src/utils/utils.h index 0262b211817c605177da4e428b55e9f183300d95..e4ec72c5ad6944282a8a1d68184dc9a4ee53d5b1 100644 --- a/src/utils/utils.h +++ b/src/utils/utils.h @@ -36,7 +36,8 @@ class Utils static const QString getDatabaseName(ExternalDatabase database); static const QString getXmlDouble(pappso::pappso_double number); static const QString checkXtandemVersion(const QString &tandem_bin_path); - static const double computeFdr(std::size_t count_decoy, std::size_t count_target); + static const double computeFdr(std::size_t count_decoy, + std::size_t count_target); static pappso::AaModificationP guessAaModificationPbyMonoisotopicMassDelta(pappso::pappso_double mass); static pappso::AaModificationP