当前位置: 首页>>代码示例>>C++>>正文


C++ ConsensusFeature::getQuality方法代码示例

本文整理汇总了C++中ConsensusFeature::getQuality方法的典型用法代码示例。如果您正苦于以下问题:C++ ConsensusFeature::getQuality方法的具体用法?C++ ConsensusFeature::getQuality怎么用?C++ ConsensusFeature::getQuality使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ConsensusFeature的用法示例。


在下文中一共展示了ConsensusFeature::getQuality方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: ConsensusFeature

	TEST_EQUAL(result[0].getQuality(), 0.0);

	// intermediate cases:
	// basis: feat1 < feat2 < feat3
	input[1].clear();
	input[0].push_back(ConsensusFeature(0, feat1));
	input[1].push_back(ConsensusFeature(1, feat2));
	spf.run(input, result);
	ConsensusFeature cons1 = result[0];
	TEST_EQUAL(cons1.size(), 2);
	input[0] = result;
	input[1][0] = ConsensusFeature(2, feat3);
	spf.run(input, result);
	ConsensusFeature cons2 = result[0];
	TEST_EQUAL(cons2.size(), 3);
	TEST_EQUAL(cons1.getQuality() > 0.0, true);
	TEST_EQUAL(cons2.getQuality() > 0.0, true);
	TEST_EQUAL(cons1.getQuality() < 1.0, true);
	TEST_EQUAL(cons2.getQuality() < 1.0, true);
	// quality(feat1, feat2) > quality((feat1, feat2), feat3):
	TEST_EQUAL(cons1.getQuality() > cons2.getQuality(), true);
	input[0].clear();
	input[0].push_back(ConsensusFeature(1, feat2));
	spf.run(input, result);
	ConsensusFeature cons3 = result[0];
	// quality(feat2, feat3) > quality(feat1, feat2), feat3):
	TEST_EQUAL(cons3.getQuality() > cons2.getQuality(), true);
	input[0][0] = ConsensusFeature(0, feat1);
	spf.run(input, result);
	ConsensusFeature cons4 = result[0];
	// quality(feat1, feat3) < quality(feat1, feat2), feat3):
开发者ID:BioinformaticsArchive,项目名称:OpenMS,代码行数:31,代码来源:StablePairFinder_test.cpp

示例2: DataValue

TEST_EQUAL(map.getUnassignedPeptideIdentifications()[1].getHits()[0].getSequence(), "G")
TEST_EQUAL(map.getUnassignedPeptideIdentifications()[1].getHits()[1].getSequence(), "H")

//features
TEST_EQUAL(map.size(), 6)
ConsensusFeature cons_feature = map[0];
TEST_REAL_SIMILAR(cons_feature.getRT(), 1273.27)
TEST_REAL_SIMILAR(cons_feature.getMZ(), 904.47)
TEST_REAL_SIMILAR(cons_feature.getIntensity(), 3.12539e+07)
TEST_REAL_SIMILAR(cons_feature.getPositionRange().minPosition()[0], 1273.27)
TEST_REAL_SIMILAR(cons_feature.getPositionRange().maxPosition()[0], 1273.27)
TEST_REAL_SIMILAR(cons_feature.getPositionRange().minPosition()[1], 904.47)
TEST_REAL_SIMILAR(cons_feature.getPositionRange().maxPosition()[1], 904.47)
TEST_REAL_SIMILAR(cons_feature.getIntensityRange().minPosition()[0], 3.12539e+07)
TEST_REAL_SIMILAR(cons_feature.getIntensityRange().maxPosition()[0], 3.12539e+07)
TEST_REAL_SIMILAR(cons_feature.getQuality(), 1.1)
TEST_EQUAL(cons_feature.getMetaValue("peptide_id") == DataValue("RefSeq:NC_1234"), true)
ConsensusFeature::HandleSetType::const_iterator it = cons_feature.begin();
TEST_REAL_SIMILAR(it->getIntensity(), 3.12539e+07)

cons_feature = map[5];
TEST_REAL_SIMILAR(cons_feature.getRT(), 1194.82)
TEST_REAL_SIMILAR(cons_feature.getMZ(), 777.101)
TEST_REAL_SIMILAR(cons_feature.getIntensity(), 1.78215e+07)
TEST_REAL_SIMILAR(cons_feature.getPositionRange().minPosition()[0], 1194.82)
TEST_REAL_SIMILAR(cons_feature.getPositionRange().maxPosition()[0], 1194.82)
TEST_REAL_SIMILAR(cons_feature.getPositionRange().minPosition()[1], 777.101)
TEST_REAL_SIMILAR(cons_feature.getPositionRange().maxPosition()[1], 777.101)
TEST_REAL_SIMILAR(cons_feature.getIntensityRange().minPosition()[0], 1.78215e+07)
TEST_REAL_SIMILAR(cons_feature.getIntensityRange().maxPosition()[0], 1.78215e+07)
TEST_REAL_SIMILAR(cons_feature.getQuality(), 0.0)
开发者ID:aiche,项目名称:open-ms-mirror,代码行数:31,代码来源:ConsensusXMLFile_test.C


注:本文中的ConsensusFeature::getQuality方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。