pdahal has asked for the wisdom of the Perl Monks concerning the following question:

I want to extract the words that are mentioned in PubMed abstracts only. I used the code below. But my programs extracts the words that are outside the abstract too. For example: i need to extract NOV if it is in the abstract but some PubMed ids contain NOV as date and outside the abstract and even that is extracted. How can i solve this?

my $args = "db=pubmed&id=$id[$i]&retmode=text&rettype=abstract"; my $req = new HTTP::Request POST => 'https://eutils.ncbi.nlm.nih.g +ov/entrez/eutils/efetch.fcgi'; $req->content_type('application/x-www-form-urlencoded'); $req->content($args); my $response = $ua->request($req); my $content = $response->content;

Replies are listed 'Best First'.
Re: Extracting abstract
by Corion (Patriarch) on Mar 01, 2017 at 12:56 UTC

    Can you show us some representative and short good and bad cases where your extraction succeeds or fails?

    In your code, I do not find any code that would extract the abstract, so I don't know what the response could look like and where you extract it.

    A reply falls below the community's threshold of quality. You may see it by logging in.