Re: python newbie

2014-06-18 Thread Jim Gibson
ython code here or provide a link to code posted elsewhere for additional help. Good luck. -- Jim Gibson -- https://mail.python.org/mailman/listinfo/python-list

Re: querry on queue ( thread safe ) multithreading

2014-03-11 Thread Jim Gibson
ate of other people's resources and a better web citizen. It is also much easier to program. -- Jim Gibson -- https://mail.python.org/mailman/listinfo/python-list

Re: [OT] Usage of U+00B6 PILCROW SIGN

2014-02-04 Thread Jim Gibson
In article , Michael Torrie wrote: > On 02/04/2014 08:21 AM, wxjmfa...@gmail.com wrote: > > > > Useless and really ugly. > > How do you recommend we discover the anchor links for linking to? Use the Table Of Contents panel on the left? -- Jim Gibson -- https://ma

Re: Basic Python Questions - Oct. 31, 2013

2013-11-03 Thread Jim Gibson
done this in the past, but not recently. This should work for Python (os.system("gnuplot gnuplot.cmd") or Perl (system("gnuplot gnuplot.cmd") with suitable commands to execute external programs. -- Jim Gibson -- https://mail.python.org/mailman/listinfo/python-list

Re: Python on a MacBook Pro (not my machine)

2013-10-28 Thread Jim Gibson
/products/bbedit/> <http://www.barebones.com/products/textwrangler/> <http://code.google.com/p/macvim/> -- Jim Gibson -- https://mail.python.org/mailman/listinfo/python-list

Re: finding data from two different files.

2013-10-18 Thread Jim Gibson
c 85 > x ef 123 > w de 33 > > Regards../ omps Interestingly, somebody named "Om Prakash Singh" asked the identical question on the perl beginners list, except with the word "perl" substituted for "python". Is this a homework problem? Are you unsure about which language to use? Are you comparison shopping? -- Jim Gibson -- https://mail.python.org/mailman/listinfo/python-list

Re: Mathematica 7 compares to other languages

2008-12-11 Thread Jim Gibson
ow gather code solutions in ruby, python, C, Java, here: > > € A Example of Mathematica's Expressiveness > http://xahlee.org/UnixResource_dir/writ/Mathematica_expressiveness.html > > now lacking is perl, elisp, which i can do well in a condensed way. > It'd be int

Re: XML -> Tab-delimited text file (using lxml)

2008-11-19 Thread Gibson
On Nov 19, 11:03 am, Stefan Behnel <[EMAIL PROTECTED]> wrote: > > Use iterparse() instead of parsing the file into memory completely. > > *stuff* > > Stefan That worked wonders. Thanks a lot, Stefan. So, iterparse() uses an iterate -> parse method instead of parse() and iter()'s parse -> iterate

XML -> Tab-delimited text file (using lxml)

2008-11-19 Thread Gibson
I'm attempting to do the following: A) Read/scan/iterate/etc. through a semi-large XML file (about 135 mb) B) Grab specific fields and output to a tab-delimited text file The only problem I'm having is that the tab-delimited text file requires a different order of values than which appear in the X

Re: Fortran vs Python - Newbie Question

2007-03-27 Thread Alex Gibson
"Beliavsky" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > On Mar 26, 10:16 am, [EMAIL PROTECTED] (Cameron Laird) wrote: >> In article >> <[EMAIL PROTECTED]>,[EMAIL PROTECTED] >> <[EMAIL PROTECTED]> wrote: > >> >Is there a mac version?? >> >Thanks >> >Chris >> >> Yes. >> >> Sever

Re: A Sort Optimization Technique: decorate-sort-dedecorate

2006-08-28 Thread Jim Gibson
ly N times. The sort can then use these pre-computed keys to sort the objects. See, for example: http://en.wikipedia.org/wiki/Schwartzian_transform -- Jim Gibson Posted Via Usenet.com Premium Usenet Newsgroup Services -- ** SPEED

Re: determine file type

2006-03-26 Thread Mark Gibson
> > > import os > def test_file(filename, maxread=1024): >if os.path.isdir(filename): > return 'directory' >afile = open(filename) # open as text >for achar in afile.read(maxread): > if ord(achar) > 127: >return 'binary' >return 'text' > > Pefect, thanks! --

determine file type

2006-03-26 Thread Mark Gibson
Is there an equivalent to the unix 'file' command? [mark tmp]$ file min.txt min.txt: ASCII text [mark tmp]$ file trunk trunk: directory [mark tmp]$ file compliance.tgz compliance.tgz: gzip compressed data, from Unix What I really want to do is determine if a file is 1) a directory, 2) a text fil