Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7962129
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T05:14:52+00:00 2026-06-04T05:14:52+00:00

I have an ID code representative of a protein. There is website called InterPro

  • 0

I have an ID code representative of a protein. There is website called InterPro that is used to deal with proteins related information. URL for that website contains that particular code. By changing that code in that URL I can get information about any protein. I developed a script in perl to get information directly from web. I used following code

    my $uniprot= "P15700";
    my $resp= '';
    my $url= "http://wwwdev.ebi.ac.uk/interpro/ISearch?query=$uniprot+";
    my $file = "$uniprot";
    $resp = getstore( $url, $file ); 


exit;
}

In this example P15700 is that unique ID of protein and the url is http://wwwdev.ebi.ac.uk/interpro/ISearch?query=P15700+. Now this will retrieve whole html page. But, I need a particular information on that page which under the heading of “protein family membership”. Like in this example If you open this link you can find “Adenylate kinase” written under heading of protein family membership. I just neeed to that information in another output text file displaying a table in which one column says ID and other says that information under protein family membership.
I am new to perl and I don’t have computer science background. Rather I am a biologist. So, I want to know whether the above mentioned task can be done using perl. If yes, How?
I ll be grateful if anyone can solve this problem.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-04T05:14:53+00:00Added an answer on June 4, 2026 at 5:14 am

    Not even sexy, but it works (based on HTML::Treebuilder Module) – you have to parse the HTML and extract the information. In this example the result will be stored as csv in the File “result.txt”

    use LWP::Simple;
    use HTML::TreeBuilder;
    
    my $uniprot= "P15700";
    my $url= "http://wwwdev.ebi.ac.uk/interpro/ISearch?query=$uniprot+";
    my $resp = get( $url );
    
    my $tree = HTML::TreeBuilder->new_from_content($resp);
    my $first=$tree->look_down(_tag => 'div',class => 'prot_fam') ;
    $first=$first->look_down(_tag => 'div',class => 'entry-parent');
    $first=$first->look_down(_tag => 'div',class => 'entry-parent');
    $first=$first->look_down(_tag => 'a');
    open (FH,">>result.txt");
    print FH $uniprot.";";
    print FH $first->content_list;
    print FH "\n";
    close(FH);
    

    Edit:
    Here’s a variant for checking lot’s of “uniprots”. Play around with the sleepdelay

    use LWP::Simple;
    use HTML::TreeBuilder;
    
    my @ports=qw(Q9H4B7 Q96RI1 P04150 P35354 P23219 P61073 P0A3M6 Q8DR59 Q7CRA4 Q27738 P35367 P35367 P35367 P08172 P35367 P10275 P25021 P07550 P08588 P13945);
    
    for (my $i=0;$i < scalar(@ports);$i++) {
    my $url= "http://wwwdev.ebi.ac.uk/interpro/ISearch?query=".$ports[$i]."+";
    my $resp = get( $url );
    
    my $tree = HTML::TreeBuilder->new_from_content($resp);
    my $first=$tree->look_down(_tag => 'div',class => 'prot_fam') ;
    $first=$first->look_down(_tag => 'div',class => 'entry-parent');
    $first=$first->look_down(_tag => 'div',class => 'entry-parent');
    $first=$first->look_down(_tag => 'a');
    open (FH,">>result.txt");
    print FH $ports[$i].";";
    print FH $first->content_list;
    print FH "\n";
    close(FH);
    sleep 10;
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

hey there guys and girls i have this code that saves json as a
I have code that looks like this: template<class T> class list { public: class
I have code that I want to look like this: List<Type> Os; ... foreach
I have code that uses Win API function RegSaveKeyEx to save registry entries to
I have code that uses jquery.slideup and jquery.slidedown How can i know that div
I have code similar to the following with a URL like this... If I
I have code that calls an ENTRY in a SUBROUTINE before the SUBROUTINE .
I have code in global.asax that sets some things in cache with CacheItemRemovedCallback. When
I have code, similar to the following, that I would like to modify: Sub
I have the following representative code: __global__ void func() { register ushort4 result =

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.