private function frequency(array $sample) : int { return count(array_filter($this->samples, function ($entry) use($sample) { return $this->subset($entry, $sample); })); }