def _filter(self, id, citing_pmcids, filter_ptype):
        pmcids_string = " OR ".join(["PMC"+pmcid for pmcid in citing_pmcids])
        query_string = filter_ptype + "[ptyp] AND (" + pmcids_string + ")"
        pmcid_filter_url = self.metrics_pmc_filter_url_template %query_string
        page = self._get_eutils_page(pmcid_filter_url, id)
        (doc, lookup_function) = provider._get_doc_from_xml(page)  
        try:    
            id_docs = doc.getElementsByTagName("Id")
            pmids = [id_doc.firstChild.data for id_doc in id_docs]
        except __HOLE__:
            logger.warning(u"%20s no Id xml tags for %s" % (self.provider_name, id))
            pmids = []
        return pmids
dataset/ETHPy150Open Impactstory/total-impact-webapp/totalimpact/providers/pubmed.py/Pubmed._filter