[BangPypers] list to dictionary problem

2010-06-21 Thread Vikram
ict(a) >>> z {'dog': 6, 'cat': 9} Is there any elegant way to extract the value 2? (Value corresponding to the first occurence of 'cat' in the 2-D list). Thanks, Vikram ___ BangPypers mailing list BangPypers@python.org http://mail.python.org/mailman/listinfo/bangpypers

[BangPypers] sorting of list

2010-06-24 Thread Vikram
Suppose i have this: -- >>> z1 = >>> [[34,44,'1011'],[40,60,'1011'],[50,50,'1013'],[40,20,'1011'],[10,30,'1013']] >>> z1 [[34, 44, '1011'], [40, 60, '1011'], [50, 50, '1013'], [40, 20, '1011'], [10, 30, '1013']] >>> for i in z1: print i [34, 44, '1011'] [40, 60, '1011'] [50, 50, '1013']

[BangPypers] nested list question

2010-07-13 Thread Vikram
of an element of X (e.g. 6741 and 6751). Eventually, one should end up with a modified version of Y, let us say modY, which is a filtered version of Y in which the second element of an element of modY is contained within the second and third elements of an element of X. Any suggestions on

Re: [BangPypers] nested list question

2010-07-14 Thread Vikram
> Suppose you have two nested lists, X and Y. > A sample element of X is: > ['NM_032291', '6741', '6751', 'chr1', '+'] > > Another sample element of X is: > ['NM_001097', '51183080', '51183635', 'chr22', '+'] > > > A sample element of Y is: > ['chr1', '6746'] > > Another

[BangPypers] list problem

2010-07-22 Thread Vikram
Suppose you have the following list: >>> x =[['cat',10],['cat',20],['cat',30],['dog',5],['dog',1],['dog',3]] My problem is that i wish to obtain the following two dictionaries: xdictstart = {'cat':10, 'dog':1} xdictend = {'cat':30, 'dog':5} Any nice way to do the above? Thanks. --- Those in

Re: [BangPypers] list problem

2010-07-22 Thread Vikram
ere is a very good reason, write the simplest, most braindead code. xdictstart={} xdictend={} for item in sorted(x): xdictend[item[0]] = item[1] if not item[0] in xdictstart xdictstart[item[0]] = item[1] On Thu, Jul 22, 2010 at 3:21 PM, Vikram wrote: > Suppose you ha

[BangPypers] partial flattening of list

2010-07-26 Thread Vikram
have the following: >>> x [['NM100', 1, 2], ['NM100', 3, 4], ['NM200', 5, 6]] >>> for i in x: ... print i ... ['NM100', 1, 2] ['NM100', 3, 4] ['NM200', 5, 6] -- how does one obtain list z such that z = [['NM100',1,2,3,4],['NM200',5,6]] ___ Bang

Re: [BangPypers] partial flattening of list

2010-07-27 Thread Vikram
ul 27, 2010 at 3:16 PM, Anand Balachandran Pillai < abpil...@gmail.com> wrote: > > > On Tue, Jul 27, 2010 at 2:29 PM, Shekhar Tiwatne wrote: > >> On Tuesday 27 July 2010 12:18 PM, Vikram wrote: >> >>> have the following: >>&g

[BangPypers] list question

2013-12-05 Thread Vikram K
Any suggestions on what i have to do to go from x to y? >>> x = [['cat','NM123',12],['cat','NM234',12], ['dog', 'NM56',65]] >>> x [['cat', 'NM123', 12], ['cat', 'NM234', 12], ['dog', 'NM56', 65]] >>> y = [] >>> y = [['cat','NM123, NM234', 12], ['dog', 'NM56', 65]] >>> Regards Vik

[BangPypers] [JOB] Startups & living the entrepreneurial dream.

2014-08-22 Thread Vikram Ahuja
email me with any questions. Thanks, Vikram ___ BangPypers mailing list BangPypers@python.org https://mail.python.org/mailman/listinfo/bangpypers

Re: [BangPypers] [JOBS] Looking for python/bash profiles

2014-10-12 Thread Vikram Upadhya
Hi Shreyas, Could you help conect me to Jobs with about 4 Years experience on Scripting Languages. With regards, Vikram U 9916028682 On Fri, Oct 10, 2014 at 2:13 PM, Kulkarni, Shreyas wrote: > Hi guys, > > We are looking for strong python and bash profiles in my team

[BangPypers] help

2016-11-22 Thread Vikram Katju
Please unsubscribe me from the list. I've forgotten my password and am not able to unsubscribe from the online site. On Tue, Nov 22, 2016 at 12:00 PM, wrote: > Send BangPypers mailing list submissions to > bangpypers@python.org > > To subscribe or unsubscribe via the World Wide Web, visi

[BangPypers] help..

2009-08-13 Thread Vikram Seth
hi all.. i am a fresher.. i have been workin on python from a few months now.. i wanted to enquire if there are any internship programs for freshers on python in any of the companies in india or are there any jobs for the freshers with the basic knowledge on python.

[BangPypers] nested list help

2010-07-27 Thread Vikram K
Suppose i have this nested list: >>> x [['NM100', 3, 4, 5, 6, 7], ['NM100', 10, 11, 12, 13], ['NM200', 15, 16, 17]] >>> for i in x: ... print i ... ['NM100', 3, 4, 5, 6, 7] ['NM100', 10, 11, 12, 13] ['NM200', 15, 16, 17] >>> how do i obtain from the above the following nested list: >>> z [['NM

[BangPypers] string to list query

2010-08-04 Thread Vikram K
Suppose i have this string: z = 'AT/CG' How do i get this list: zlist = ['A','T/C','G'] ___ BangPypers mailing list BangPypers@python.org http://mail.python.org/mailman/listinfo/bangpypers

Re: [BangPypers] BangPypers Digest, Vol 38, Issue 2

2010-10-04 Thread Vikram Kamath
. Beginner help (Dennis Varkey) > 2. Re: Beginner help (delegb...@dudupay.com) > 3. Re: Beginner help (Senthil Kumaran) > 4.Re: Beginner help (Vikram Kamath) > > > -- > > Message: 1 > Date: Sat, 2 Oct 20

Re: [BangPypers] BangPypers Digest, Vol 41, Issue 27

2011-01-16 Thread Vikram Kamath
Well, you could always try a different method of multiplication. A common trick would be to use block multiplication. http://en.wikipedia.org/wiki/Block_matrix On Sun, Jan 16, 2011 at 4:30 PM, wrote: > Send BangPypers mailing list submissions to >bangpypers@python.org > > To subscribe or

Re: [BangPypers] BangPypers Digest, Vol 46, Issue 29

2011-06-30 Thread Vikram Kamath
> > Message: 6 > Date: Thu, 30 Jun 2011 19:00:04 +0530 > From: Puneet Aggarwal > To: Bangalore Python Users Group - India > Subject: Re: [BangPypers] Spell Checker Python > Message-ID: > Content-Type: text/plain; charset=ISO-8859-1 > > On Thu, Jun 30, 2011 at 6:57 PM,

[BangPypers] Python programmer positions open at IIIT Hyderabad

2011-11-27 Thread Vikram Pudi
As part of a DBT sanctioned project, we need to develop a system / portal that serves as a repository of data pertaining to the metabolism (chemical reactions/pathways) of various species. Bio-labs all over India will use this portal to store, access, analyze the data that comes out of their e

[BangPypers] executing shell commands through python script

2012-08-13 Thread Vikram K
i am able to run the following command from the shell (i am working on Mac Snow Leopard): cgatools evidence2sam --beta --evidence-dnbs evidenceDnbs-chr11-GS10026-ASM-T1.tsv.bz2 --reference build36.crr --output CGI_10026_CLL046_chr11_NUMA1_N.sam --extract-genomic-region chr11,71391559,71469221