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 8236547
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T19:10:10+00:00 2026-06-07T19:10:10+00:00

The common code is : use strict; use warnings; my $f = $ARGV[0]; use

  • 0

The common code is :

use strict;
use warnings;

my $f = $ARGV[0];
use Bio::EnsEMBL::Registry;
use Bio::EnsEMBL::ApiVersion;

my $registry = 'Bio::EnsEMBL::Registry';
$registry->load_registry_from_db(
-host => 'ensembldb.ensembl.org',
-user => 'anonymous',
-port => '5306'
);

my $adaptor = $registry->get_adaptor( 'Homo sapiens', 'core', 'transcript' );

my $transcript =
$adaptor->fetch_by_translation_stable_id($f);

LAST LINE

#

For the LAST LINE, I am having trouble printing out the two values as two columns in the same line :

Attempt 1 code: print $f . $transcript->display_id. “\n”;

Result : api.test.pl ENSP00000418690

ENSP00000418690ENST00000488594

Attempt 2 code :print $f, $transcript->display_id. “\n”;

Result : perl api.test.pl ENSP00000418690 :

ENSP00000418690ENST00000488594

Any other attempt messes with accessing the display_id. What I want the format to be is :
ENSP00000418690 ENST00000488594

  • 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-07T19:10:11+00:00Added an answer on June 7, 2026 at 7:10 pm

    If you want a space between the values, print a space between the values.

    print $f, " ", $transcript->display_id, "\n";
    

    The dot joins two strings into one string, which isn’t necessary here, because print accepts a comma-separated list of values.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have the following perl code : use strict; use warnings; use Test::Cmd::Common; my
A common piece of code I use for simple string splitting looks like this:
When writing Common Lisp code, I use SLIME. In particular, I compile the buffer
I am trying to use org.apache.commons.collections.CollectionUtils in android with following code import java.util.ArrayList; import
We have a repository of common code on svn that we use for many
I have this code #!/usr/bin/perl -w use strict; use URI; use LWP::UserAgent; use Data::Dumper;
I have such script: (Script.pl) #!/usr/bin/perl use strict; use warnings; use encoding 'utf-8'; use
I'm making a framework (for internal use only) that has common code among 3
This is REALLY frustrating! I have a common library of code I use across
I'm creating a project to house an iPhone library for common code for the

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.