
"be consistent"

Re: Extracting Unique elements

by wind (Priest)
on Jun 14, 2011 at 23:49 UTC ( #909671=note: print w/ replies, xml ) Need Help??

Comment on Re: Extracting Unique elements
Re^2: Extracting Unique elements
by smandape1 (Acolyte) on Jun 16, 2011 at 16:50 UTC

    I tried, but I am unable to use them directly. The thing is the data 'title' gets extracted twice for more than one users because of the loop. I want to restrict the loop to extract elements like title, PMID and list of authors only once. And I want to do it while I am extracting it. It seems that I can remove the duplicates later but, it all messes up. Because there are some users and tags that are duplicates too, but I want them. Can you help please.

      Just use a %seen hash like demonstrated in the resource I linked you to. It will enable you to filter out any duplicates as you go just as easily as removing duplicates after the fact.






        Thanks Wind. I really appreciate your help. Okay, while I was playing around with perl code, I found something interesting. Probably you can explain it to me in better way. I was trying to use get() for a webquery. Something like below:

        $url = "$d +b1&id=$query&retmode=text&rettype=abstract"; $data = get($url);

        when I put $url in single quotes it doesn't work with the $db and $query but if I put it in double quotes it works. Why is it so, what is the relation between quotes and scalar quantity? It would be really nice if you can explain this to me. Thank you, Sammed

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://909671]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others surveying the Monastery: (14)
As of 2014-03-14 14:55 GMT
Find Nodes?
    Voting Booth?

    Have you used a cryptocurrency?

    Results (307 votes), past polls