37 #include <OpenMS/OpenMSConfig.h>
53 static void getKeys(
const T&
object, std::vector<String>& keys)
92 template<
typename T_In,
typename T_Out>
96 min_frequency = std::min(100.0f, std::max(0.0f, min_frequency));
98 std::map<String, UInt> counter;
99 typedef std::vector<String> KeysType;
101 for (
typename T_In::const_iterator it = it_start; it != it_end; ++it)
103 getter.getKeys(*it, keys);
104 for (KeysType::const_iterator itk = keys.begin(); itk != keys.end(); ++itk)
110 const UInt required_counts =
UInt(min_frequency / 100.0 * std::distance(it_start, it_end));
112 for (
const auto& [key, count] : counter)
114 if (count >= required_counts)
116 common_keys.insert(common_keys.end(), key);
unsigned int UInt
Unsigned integer type.
Definition: Types.h:94
Main OpenMS namespace.
Definition: FeatureDeconvolution.h:47