This is really a question for the Bioperl forum

2011-08-16 Thread ANJAN PURKAYASTHA
wing ouput: Bio::Taxon=HASH(0x158dbe0)->idBio::Taxon=HASH(0x158dbe0)->name The script seems to be working but there seems to be a problem with dereferencing a Bio::Taxon object. Can anyone suggest how I get to the attributes of the Bio::Taxon object? TIA, Anjan -- ===

Re: Capturing the output of a shell command

2011-04-05 Thread ANJAN PURKAYASTHA
thank you all! Anjan On Tue, Apr 5, 2011 at 9:49 AM, Shawn H Corey wrote: > On 11-04-05 09:24 AM, ANJAN PURKAYASTHA wrote: > >> Hi, >> Is there any way to run a shell command from within a perl script and >> capture the output in, say, an array? >> One can run a sh

Capturing the output of a shell command

2011-04-05 Thread ANJAN PURKAYASTHA
Hi, Is there any way to run a shell command from within a perl script and capture the output in, say, an array? One can run a shell command through the system function. But system itself just returns a status code. -- === Anjan Purkayastha, PhD Senior

Re: sequence composition

2010-12-02 Thread ANJAN PURKAYASTHA
} >else { >$seq{ $key } .= $_; > >} > } > > > > > John > -- > Any intelligent fool can make things bigger and > more complex... It takes a touch of genius - > and a lot of courage to move in the opposite > direction. -- Albert Einstein > > -- > To unsubscribe, e-mail: beginners-unsubscr...@perl.org > For additional commands, e-mail: beginners-h...@perl.org > http://learn.perl.org/ > > > -- === anjan purkayastha, phd. research associate fas center for systems biology, harvard university 52 oxford street cambridge ma 02138 phone-703.740.6939 ===

Re: sequence composition

2010-12-01 Thread ANJAN PURKAYASTHA
ost a sample of input > data and the corresponding output you desire then I am sure we can help. > > Regards, > > Rob > > > -- > To unsubscribe, e-mail: beginners-unsubscr...@perl.org > For additional commands, e-mail: beginners-h...@perl.org > http://learn.perl.org/ > > > -- === anjan purkayastha, phd. research associate fas center for systems biology, harvard university 52 oxford street cambridge ma 02138 phone-703.740.6939 ===

Re: question on software development

2010-03-07 Thread ANJAN PURKAYASTHA
. Anjan -- = anjan purkayastha, phd * research associate* fas center for systems biology, * harvard university * =

Re: question on software development

2010-03-05 Thread ANJAN PURKAYASTHA
AM, Shlomi Fish wrote: > On Friday 05 Mar 2010 06:27:51 David Christensen wrote: > > ANJAN PURKAYASTHA wrote: > > > OK, suppose I develop a Perl application. I want to create an icon for > > > the program so that a user may download the program and start it in th

question on software development

2010-03-04 Thread ANJAN PURKAYASTHA
OK, suppose I develop a Perl application. I want to create an icon for the program so that a user may download the program and start it in the GUI by double-clicking on the icon. How does one go about doing it? TIA, Anjan -- = anjan purkayastha, phd

Re: listing all modules

2010-01-29 Thread ANJAN PURKAYASTHA
les are installed > on my system?" in perlfaq3. You can see a list of all FAQ answers by looking > in perlfaq." > > Credit should be given to brian d. foy and pjf for the answer above. > > > > Jeremiah > > > > On Jan 29, 2010, at 4:55 PM, ANJAN PURKAYAST

listing all modules

2010-01-29 Thread ANJAN PURKAYASTHA
Hi, Is there a command that lists all installed perl modules in my .cpan directory? TIA, Anjan -- = anjan purkayastha, phd * research associate* fas center for systems biology, * harvard university * =

Re: Working with Excel spreadsheets

2010-01-25 Thread ANJAN PURKAYASTHA
ading through that module but wanted to find something > bit simpler to use, like the DataFromExcel or Excel2Text then work with the > exported data. Think we'll do some testing and see which one will suite our > need. > > Thanks for the help > > Mike >

System question

2010-01-13 Thread ANJAN PURKAYASTHA
TIA, Anjan -- ===== anjan purkayastha, phd * research associate* fas center for systems biology, * harvard university * =

A question on filehandles

2009-10-28 Thread ANJAN PURKAYASTHA
Trying to learn how to run Gnuplot via a Perl script I came across the following helpful example: #!/usr/bin/perl # Generate postscript and png plot with GNUplot from Perl # Author: Ioan Vancea # Usage: Give "data file" as an argument for script use strict; use warnings; my $file = ARGV[0]; # P

Problem with PDF::API2::Lite module

2009-10-22 Thread ANJAN PURKAYASTHA
/Resource/XObject/Image.pm line 99. Does anyone else on this forum use this module? If so any insight on how I can correct it? Many thanks in advance. Anjan -- = anjan purkayastha, phd bioinformatics analyst whitehead institute for biomedical research nine cambridg

Burnt camel etc. etc

2009-09-23 Thread ANJAN PURKAYASTHA
eat job in helping newbies. It would be a shame to change things. JMTC, Anjan -- ===== anjan purkayastha, phd bioinformatics analyst whitehead institute for biomedical research nine cambridge center cambridge, ma 02142 purkayas [at] wi [dot] mit [dot] edu 703.740.6939

Re: Creating array variable names on the fly

2009-08-28 Thread ANJAN PURKAYASTHA
Thanks for your feedback guys. I think I have enough material to start coding. Cheers! Anjan On Fri, Aug 28, 2009 at 9:32 AM, Steve Bertrand wrote: > Jenda Krynicky wrote: > > From: ANJAN PURKAYASTHA > >> Hi, > >> I have a question on creating array variables. I

Creating array variable names on the fly

2009-08-28 Thread ANJAN PURKAYASTHA
into the child script: read the number of files to be processed. based on this number create a set of arrays say @array1, @array2@array7"? Appreciate your feedback. TIA, Anjan -- = anjan purkayastha, phd bioinformatics analyst whitehead institute for biome

Re: Help with LWP

2009-05-13 Thread ANJAN PURKAYASTHA
Yes tried the URL; http://www.ncbi.nlm.nih.gov/coreutils/dispatch.cgi. Got a "302 Found at lwp_test.pl line 23" error message. Thanks Anjan On Wed, May 13, 2009 at 5:57 PM, Dermot wrote: > 2009/5/13 Jim Gibson : > > On 5/13/09 Wed May 13, 2009 2:17 PM, "ANJAN PUR

Help with LWP

2009-05-13 Thread ANJAN PURKAYASTHA
content()."\n"; # or whatever } else { die $response->status_line; } All this script returns is the NCBI homepage. Any idea what I am doing wrong? TIA, Anjan -- = anjan purkayastha, phd bioinformatics analyst whitehead institute for biomedical research nine cambridge center cambridge, ma 02142 purkayas [at] wi [dot] mit [dot] edu 703.740.6939

Perl wrapper

2009-04-20 Thread ANJAN PURKAYASTHA
them? -- = anjan purkayastha, phd bioinformatics analyst whitehead institute for biomedical research nine cambridge center cambridge, ma 02142 purkayas [at] wi [dot] mit [dot] edu 703.740.6939

Re: Random number generator

2009-04-09 Thread ANJAN PURKAYASTHA
Thank you guys. Anjan On Thu, Apr 9, 2009 at 6:59 PM, Chas. Owens wrote: > On Thu, Apr 9, 2009 at 17:34, ANJAN PURKAYASTHA > wrote: > > I need a Bernoulli random number generator which takes as inputs: a value > > for p(1) (probability of choosing a "1")

Random number generator

2009-04-09 Thread ANJAN PURKAYASTHA
TIA, Anjan -- ===== anjan purkayastha, phd bioinformatics analyst whitehead institute for biomedical research nine cambridge center cambridge, ma 02142 purkayas [at] wi [dot] mit [dot] edu 703.740.6939

Re: LWP

2009-04-08 Thread ANJAN PURKAYASTHA
to all, thanks for your prompt replies. You guys are great! Anjan On Wed, Apr 8, 2009 at 4:29 PM, Gunnar Hjalmarsson wrote: > Telemachus wrote: > >> On Wed Apr 08 2009 @ 3:22, ANJAN PURKAYASTHA wrote: >> >>> I have a file stored at a location: http://parent_dir/fil

LWP

2009-04-08 Thread ANJAN PURKAYASTHA
I have a file stored at a location: http://parent_dir/file Which among gazillion LWP options can I use to download and store the file on my machine? TIA Anjan -- = anjan purkayastha, phd bioinformatics analyst whitehead institute for biomedical research nine

Array question

2009-03-30 Thread ANJAN PURKAYASTHA
Hi, Here is my problem; I have a series of arrays with 0s and 1s. here is an example: (1, 0, 1, 1). I need to parse through this series of arrays and extract the index of the 0s in the array. Is there any quick way of doing this? TIA, Anjan -- = anjan purkayastha, phd

Perl-R bridge

2009-01-18 Thread ANJAN PURKAYASTHA
. Suggestions on alternate solutions will be appreciated. Thanks in advance, Anjan -- ===== anjan purkayastha, phd bioinformatics analyst whitehead institute for biomedical research nine cambridge center cambridge, ma 02142 purkayas [at] wi [dot] mit [dot] edu 703.740.6939

Re: Floating point question

2009-01-14 Thread ANJAN PURKAYASTHA
yes modf seems to be the best solution. thanks to all for your feedback! anjan On Tue, Jan 13, 2009 at 7:36 PM, Rob Dixon wrote: > ANJAN PURKAYASTHA wrote: > > Owen wrote: > >> ANJAN PURKAYASTHA wrote: > >>> > >>> I would like to divide

Re: Floating point question

2009-01-13 Thread ANJAN PURKAYASTHA
e liner, but here is a logical way of > achieving the result > > > #!/usr/bin/perl -w > > use strict; > > my $nr = "12.75"; > > my ( $whole, $part ) = ( int($nr), $nr - int($nr) ); > > print "$whole $part\n "; > > > > > Owen > >

Floating point question

2009-01-13 Thread ANJAN PURKAYASTHA
Hi, I would like to divide a floating point number into its whole and fractional parts. So, ($w, $f)= some_subroutine(12.735) assigns 12 to $w and 0.735 to $f. Any easy perlish way of doing this? TIA, Anjan -- = anjan purkayastha, phd bioinformatics analyst

Re: help with format conversion

2009-01-11 Thread ANJAN PURKAYASTHA
un, Jan 11, 2009 at 2:41 PM, Mr. Shawn H. Corey wrote: > On Sun, 2009-01-11 at 13:41 -0500, ANJAN PURKAYASTHA wrote: > > hi, > > i have file of numbers in the format x.e+003, eg 2.133793e+001. > > these numbers are not recognized by the perl multiplication operator > > &

help with format conversion

2009-01-11 Thread ANJAN PURKAYASTHA
hi, i have file of numbers in the format x.e+003, eg 2.133793e+001. these numbers are not recognized by the perl multiplication operator "*". any idea of how i may convert these numbers to a format the operator DOES recognize? thanks, anjan -- ===== anjan p

Re: pattern matching question

2008-09-23 Thread ANJAN PURKAYASTHA
;Cannot open file: $!"; #(example.txt is file > containing your column) > undef $/; > my $text = ; > $text=~s/[^AGTC]//g; #remove anything which is not A,G,T or C > print "$text"; # $text will contain your required output > > Let me know if this helps. >

pattern matching question

2008-09-22 Thread ANJAN PURKAYASTHA
tried if($x=~ /[ATGC]/ )then . however this pattern matching expression is unable to filter out the non-DNA sequences. i have also tried other expressions too convoluted to write out here. any ideas? tia, anjan -- = anjan purkayastha, phd bioinformatics analyst

Re: file manipulation

2008-08-21 Thread ANJAN PURKAYASTHA
shawn, thanks for the pointers. looks like you have saved me from buying more disks ;)! anjan On Thu, Aug 21, 2008 at 3:40 PM, Mr. Shawn H. Corey <[EMAIL PROTECTED]>wrote: > On Thu, 2008-08-21 at 15:23 -0400, ANJAN PURKAYASTHA wrote: > > ok here is the problem. i have a limited a

file manipulation

2008-08-21 Thread ANJAN PURKAYASTHA
utput to the output file. this reduction in input file size along with a simultaneous increase in the output file size will ensure that i do not overshoot the quota. does anyone have pointers on how to accomplish this in perl. tia, anjan -- ===== anjan purkayastha, phd bi

hash of arrays

2008-08-18 Thread ANJAN PURKAYASTHA
hi, i'm struggling with a hash of arrays problem. suppose i create the following HOA: $HOA{$key}= [qw(a,b,c,d)]; how do i push an element into the $HOA{$key} array? tia, anjan -- = anjan purkayastha bioinformatics analyst whitehead institute for biomedical res

Re: parsing a large excel file

2008-07-22 Thread ANJAN PURKAYASTHA
5:11 AM, Stewart Anderson < [EMAIL PROTECTED]> wrote: > > > -Original Message- > > From: Stewart Anderson > > Sent: 22 July 2008 09:34 > > To: ANJAN PURKAYASTHA; beginners@perl.org > > Cc: Stewart Anderson > > Subject: RE: parsing a large e

parsing a large excel file

2008-07-21 Thread ANJAN PURKAYASTHA
ted. tia, anjan -- ===== anjan purkayastha bioinformatics analyst whitehead institute for biomedical research nine cambridge center cambridge, ma 02142 purkayas [at] wi [dot] mit [dot] edu 703.740.6939

Sorting and grouping question

2008-05-15 Thread ANJAN PURKAYASTHA
g 6 w 4 ald I can figure out the sorting. Are they any command/modules to do the grouping based on identical tokens? appreciate your input. tia, anjan -- ANJAN PURKAYASTHA, PhD. Senior Computational Biologist == 1101 King Street, Suite 310, Alexandria

Running an interactive program with filehandles

2008-03-25 Thread ANJAN PURKAYASTHA
oods, Janin, or Rose): Use of uninitialized value in scalar chomp at ./HydrophobicityProfiler.pl line 26. Use of uninitialized value in open at ./HydrophobicityProfiler.pl line 28. Cannot open the file: No such file or directory So my question is. Is it possible to write a program to run an intera

problem running Devel::ptkdb

2008-03-18 Thread ANJAN PURKAYASTHA
Can't call method "setup_main_window" on unblessed reference at /System/Library/Perl/5.8.6/Devel/ptkdb.pm line 4151. END failed--call queue aborted. can anyone help me troubleshoot? thanks, anjan -- ANJAN PURKAYASTHA, PhD. Senior Computational Biologist ==

timing a program run

2008-03-08 Thread ANJAN PURKAYASTHA
thanks to all who replied to my earlier post. just tried out NYTProfiler on my Mac OSX. it worked like a charm! cheers, anjan -- ANJAN PURKAYASTHA, PhD. Senior Computational Biologist == 1101 King Street, Suite 310, Alexandria, VA 22314. 703.518.8040 (office

Re: timing a program

2008-03-08 Thread ANJAN PURKAYASTHA
thanks all ! just tried NYTProfiler. worked like a charm! anjan On Sat, Mar 8, 2008 at 1:24 PM, zentara <[EMAIL PROTECTED]> wrote: > On Sat, 8 Mar 2008 11:27:01 -0500, [EMAIL PROTECTED] ("ANJAN > PURKAYASTHA") wrote: > > >i would like to find out how much time

timing a program

2008-03-08 Thread ANJAN PURKAYASTHA
i would like to find out how much time my program or a couple of steps within my program took to run. any idea what command/module i need to use? tia, anjan -- ANJAN PURKAYASTHA, PhD. Senior Computational Biologist == 1101 King Street, Suite 310, Alexandria, VA 22314

running two processes at the same time

2008-03-08 Thread ANJAN PURKAYASTHA
. run program X on sequence1 2. process output file1 run program X on sequence2 3. process output file2 run program X on sequence3 in other words, run program X and also process the output file of the previous X run simultaneously? all advice will be appreciated. tia. anjan -- ANJAN

Debugger question

2008-02-15 Thread ANJAN PURKAYASTHA
0. What command is used to do this? All feedback will be appreciated. TIA Anjan -- ANJAN PURKAYASTHA, PhD. Senior Computational Biologist == 1101 King Street, Suite 310, Alexandria, VA 22314. 703.518.8040 (office) 703.740.6939 (mobile) email: [EMAIL PROTECTED]; [EMAI

question on @INC

2008-01-15 Thread ANJAN PURKAYASTHA
extra paths to the @INC variable? Appreciate your help, Anjan -- ANJAN PURKAYASTHA, PhD. Senior Computational Biologist == 1101 King Street, Suite 310, Alexandria, VA 22314. 703.518.8040 (office) 703.740.6939 (mobile) email: [EMAIL PROTECTED]; [EMAIL PROTECTED] http://www.vbi.vt.edu ==

installing Math::Complex

2008-01-11 Thread ANJAN PURKAYASTHA
urned bad status, install seems imposssible. any thoughts? Anjan -- ANJAN PURKAYASTHA, PhD. Senior Computational Biologist == 1101 King Street, Suite 310, Alexandria, VA 22314. 703.518.8040 (office) 703.740.6939 (mobile) email: [EMAIL PROTECTED]; [EMAIL PROTECTED]