[SciPy-user] Automatic Indentation

Crider, Joseph A joseph.a.crider@boeing....
Mon Mar 26 13:24:21 CDT 2007


I frequently use jEdit (www.jedit.org) for editing code, and it has a
command on the Edit menu to move indentation of a selected block either
left or right, which has been very useful for me in similar situations.
I've encountered similar features on some other editors, but I can't
recall which ones right off.


J. Allen Crider

-----Original Message-----
From: Lorenzo Isella [mailto:lorenzo.isella@gmail.com] 
Sent: Monday, March 26, 2007 12:07 PM
To: scipy-user@scipy.org
Subject: [SciPy-user] Automatic Indentation

Dear All,
Again a newbie question: I am postprocessing some data files with
Python.
Let us say they are named {filea001...filea100}, {fileb001...fileb100},
{filec001...filec100} and so on.
I need to perform different operations on the three different data sets,
and I wrote a code for that.
The problem is that in the future the three data sets will not be
present simultaneously and I thought about simply defining a parameter
which assumes values {1,2,3} depending on which datasets are present and
using some if-conditions to tell the code which data it should read and
process, without changing dramatically the code structure.
Now, the problem is that I cannot simply encapsulate large parts of the
code into an if condition without also changing the indentation and this
is getting tedious and error prone.
I am sure I cannot be the first Python user to have come across this, so
I would like to know how more experienced users deal with this.
Kind Regards

Lorenzo Isella
_______________________________________________
SciPy-user mailing list
SciPy-user@scipy.org
http://projects.scipy.org/mailman/listinfo/scipy-user


More information about the SciPy-user mailing list