def narrow(self, lines: Container[TLineNo]) -> Analysis:
        """Create a narrowed Analysis.

        The current analysis is copied to make a new one that only considers
        the lines in `lines`.
        """

        statements = {lno for lno in self.statements if lno in lines}
        excluded = {lno for lno in self.excluded if lno in lines}
        executed = {lno for lno in self.executed if lno in lines}

        if self.has_arcs:
            arc_possibilities_set = {
                (a, b) for a, b in self.arc_possibilities_set
                if a in lines or b in lines
            }
            arcs_executed_set = {
                (a, b) for a, b in self.arcs_executed_set
                if a in lines or b in lines
            }
            exit_counts = {
                lno: num for lno, num in self.exit_counts.items()
                if lno in lines
            }
            no_branch = {lno for lno in self.no_branch if lno in lines}
        else:
            arc_possibilities_set = set()
            arcs_executed_set = set()
            exit_counts = {}
            no_branch = set()

        return Analysis(
            precision=self.precision,
            filename=self.filename,
            has_arcs=self.has_arcs,
            statements=statements,
            excluded=excluded,
            executed=executed,
            arc_possibilities_set=arc_possibilities_set,
            arcs_executed_set=arcs_executed_set,
            exit_counts=exit_counts,
            no_branch=no_branch,
        )
Create a narrowed Analysis.

        The current analysis is copied to make a new one that only considers
        the lines in `lines`.
        
coverage/results.py