<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: &#8220;Should I switch to Python?&#8221;</title>
	<atom:link href="http://www.programming4scientists.com/2009/11/17/should-i-switch-to-python/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.programming4scientists.com/2009/11/17/should-i-switch-to-python/</link>
	<description>Software development wisdom and common-sense for the scientist-programmer</description>
	<lastBuildDate>Mon, 16 Aug 2010 19:05:20 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Walking Randomly &#187; The rise and rise of Python in computational science</title>
		<link>http://www.programming4scientists.com/2009/11/17/should-i-switch-to-python/comment-page-1/#comment-457</link>
		<dc:creator>Walking Randomly &#187; The rise and rise of Python in computational science</dc:creator>
		<pubDate>Wed, 16 Dec 2009 11:57:32 +0000</pubDate>
		<guid isPermaLink="false">http://www.programming4scientists.com/?p=613#comment-457</guid>
		<description>[...] Should I switch to Python &#8211; Are you a MATLAB user considering the switch? [...]</description>
		<content:encoded><![CDATA[<p>[...] Should I switch to Python &#8211; Are you a MATLAB user considering the switch? [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: gioby</title>
		<link>http://www.programming4scientists.com/2009/11/17/should-i-switch-to-python/comment-page-1/#comment-451</link>
		<dc:creator>gioby</dc:creator>
		<pubDate>Mon, 23 Nov 2009 13:27:26 +0000</pubDate>
		<guid isPermaLink="false">http://www.programming4scientists.com/?p=613#comment-451</guid>
		<description>If you want to switch to python for doing calculus and matlab-like operations like the ones you describe, you should better look at:

- enthought (http://www.enthought.com/products/epd.php), which is basically an enhanced version of numpy/scipy/matplotlib, from the developers of these libraries themselves. It is like a commercial (but academic free) version of Pylab.

- sage (http://www.sagemath.org/), which allows you to write programs that call different syntaxes and scripts in matlab, R, and other programming language, and to do it with a python syntax.

In general, I would not recommend you to switch to python, because it has -way- less libraries for what you want to do compared to Matlab. For the same reason, I wouldn&#039;t recommend anyone to switch from R to python, and consider that I am a python freakie and user myself :-(

The Pylab libraries (numpy+scipy+matplotlib) have seen a lot of improvements lately, but don&#039;t expect too much from them, unless you are wishing to contribute to these libraries.</description>
		<content:encoded><![CDATA[<p>If you want to switch to python for doing calculus and matlab-like operations like the ones you describe, you should better look at:</p>
<p>- enthought (<a href="http://www.enthought.com/products/epd.php)" rel="nofollow">http://www.enthought.com/products/epd.php)</a>, which is basically an enhanced version of numpy/scipy/matplotlib, from the developers of these libraries themselves. It is like a commercial (but academic free) version of Pylab.</p>
<p>- sage (<a href="http://www.sagemath.org/)" rel="nofollow">http://www.sagemath.org/)</a>, which allows you to write programs that call different syntaxes and scripts in matlab, R, and other programming language, and to do it with a python syntax.</p>
<p>In general, I would not recommend you to switch to python, because it has -way- less libraries for what you want to do compared to Matlab. For the same reason, I wouldn&#8217;t recommend anyone to switch from R to python, and consider that I am a python freakie and user myself :-(</p>
<p>The Pylab libraries (numpy+scipy+matplotlib) have seen a lot of improvements lately, but don&#8217;t expect too much from them, unless you are wishing to contribute to these libraries.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Frederick Ross</title>
		<link>http://www.programming4scientists.com/2009/11/17/should-i-switch-to-python/comment-page-1/#comment-447</link>
		<dc:creator>Frederick Ross</dc:creator>
		<pubDate>Thu, 19 Nov 2009 13:07:02 +0000</pubDate>
		<guid isPermaLink="false">http://www.programming4scientists.com/?p=613#comment-447</guid>
		<description>@Ronald: I stand corrected.  Thank you.  But it would not be a Scheme in any way, shape, or form.  One function per file?  No macros?  A bare excuse for anonymous functions?  No.

@Rich: I will admit here that object oriented programming a la Python has never seemed like a good fit for anything I&#039;ve done, but I learned Lisp before I wrote any object oriented code at all.  This may be a peculiarity of my brain.</description>
		<content:encoded><![CDATA[<p>@Ronald: I stand corrected.  Thank you.  But it would not be a Scheme in any way, shape, or form.  One function per file?  No macros?  A bare excuse for anonymous functions?  No.</p>
<p>@Rich: I will admit here that object oriented programming a la Python has never seemed like a good fit for anything I&#8217;ve done, but I learned Lisp before I wrote any object oriented code at all.  This may be a peculiarity of my brain.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Niels Bom</title>
		<link>http://www.programming4scientists.com/2009/11/17/should-i-switch-to-python/comment-page-1/#comment-446</link>
		<dc:creator>Niels Bom</dc:creator>
		<pubDate>Wed, 18 Nov 2009 19:45:35 +0000</pubDate>
		<guid isPermaLink="false">http://www.programming4scientists.com/?p=613#comment-446</guid>
		<description>Typo: tranferable</description>
		<content:encoded><![CDATA[<p>Typo: tranferable</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jonas</title>
		<link>http://www.programming4scientists.com/2009/11/17/should-i-switch-to-python/comment-page-1/#comment-445</link>
		<dc:creator>Jonas</dc:creator>
		<pubDate>Wed, 18 Nov 2009 12:43:32 +0000</pubDate>
		<guid isPermaLink="false">http://www.programming4scientists.com/?p=613#comment-445</guid>
		<description>Python is nice, but it is a different language than Matlab although numpy makes it just as (or even more) powerful.

But why not take a look at Octave? It is very close to Matlab, much of the code runs entirely without modifications and it is easy to extend.

It would be an easier first step than porting a lot of code and knowledge to numpy.</description>
		<content:encoded><![CDATA[<p>Python is nice, but it is a different language than Matlab although numpy makes it just as (or even more) powerful.</p>
<p>But why not take a look at Octave? It is very close to Matlab, much of the code runs entirely without modifications and it is easy to extend.</p>
<p>It would be an easier first step than porting a lot of code and knowledge to numpy.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Marcin Cieslik</title>
		<link>http://www.programming4scientists.com/2009/11/17/should-i-switch-to-python/comment-page-1/#comment-444</link>
		<dc:creator>Marcin Cieslik</dc:creator>
		<pubDate>Wed, 18 Nov 2009 12:20:48 +0000</pubDate>
		<guid isPermaLink="false">http://www.programming4scientists.com/?p=613#comment-444</guid>
		<description>Objects are nice, but it requires time and a lot of refactoring to get the abstractions right. Sometimes I wish python programmers would not slice an algorithm apart and paste it into 5 methods of 3 classes.</description>
		<content:encoded><![CDATA[<p>Objects are nice, but it requires time and a lot of refactoring to get the abstractions right. Sometimes I wish python programmers would not slice an algorithm apart and paste it into 5 methods of 3 classes.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jarretinha</title>
		<link>http://www.programming4scientists.com/2009/11/17/should-i-switch-to-python/comment-page-1/#comment-443</link>
		<dc:creator>Jarretinha</dc:creator>
		<pubDate>Wed, 18 Nov 2009 11:43:56 +0000</pubDate>
		<guid isPermaLink="false">http://www.programming4scientists.com/?p=613#comment-443</guid>
		<description>I&#039;m using python for a while for my work with bioinformatics and theoretical population genetics (PG). I can say that python is really good to code proof of principle ideas. But, for real use of the code there are unacceptable drawbacks. 

It&#039;s very easy to implement fundamental PG models in python. But, whatever optimizations and clever coding one uses it will be too slow for MCMC and other simulations. The can be said to certain dynamic programming techniques in bioinformatics. Good control of speed, concurrency and numerical precision is essential in those areas.

On the other hand, a combination of python/C/FORTRAN can be a real killer. Python can be an amazing integration language. The most important numerical tasks are already coded and optimized in excelent quality libs in C/FORTRAN. Most of my actual work is to reformat data to fit into this libs.

So, one don&#039;t need to switch to python. Only needs to know where to use it. By the way, there are some wrappers to use matlab from a python shell and should be easy to write one from scratch.

Why put your resources to compete when they can just cooperate?</description>
		<content:encoded><![CDATA[<p>I&#8217;m using python for a while for my work with bioinformatics and theoretical population genetics (PG). I can say that python is really good to code proof of principle ideas. But, for real use of the code there are unacceptable drawbacks. </p>
<p>It&#8217;s very easy to implement fundamental PG models in python. But, whatever optimizations and clever coding one uses it will be too slow for MCMC and other simulations. The can be said to certain dynamic programming techniques in bioinformatics. Good control of speed, concurrency and numerical precision is essential in those areas.</p>
<p>On the other hand, a combination of python/C/FORTRAN can be a real killer. Python can be an amazing integration language. The most important numerical tasks are already coded and optimized in excelent quality libs in C/FORTRAN. Most of my actual work is to reformat data to fit into this libs.</p>
<p>So, one don&#8217;t need to switch to python. Only needs to know where to use it. By the way, there are some wrappers to use matlab from a python shell and should be easy to write one from scratch.</p>
<p>Why put your resources to compete when they can just cooperate?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Roland Kaufmann</title>
		<link>http://www.programming4scientists.com/2009/11/17/should-i-switch-to-python/comment-page-1/#comment-442</link>
		<dc:creator>Roland Kaufmann</dc:creator>
		<pubDate>Wed, 18 Nov 2009 11:29:45 +0000</pubDate>
		<guid isPermaLink="false">http://www.programming4scientists.com/?p=613#comment-442</guid>
		<description>@Frederick:

Matlab has had just-in-time compilation for quite some time (since v6.5), and it is even possible to partially precompile code to a bytecode format through the pcode function.

Newer versions have both classes and modules, and should be comparable to Python when it comes to code base organization.

IMHO, the real problem with Matlab is that there is some old legacy cruft which still enables people to &quot;code FORTRAN&quot; in it, and which Mathworks are reluctant to deprecate, in order to maintain backwards compatibility. 

A &quot;cleansed&quot; version would be preferrable, and would probably feel a lot like Scheme with matrices instead of lists.</description>
		<content:encoded><![CDATA[<p>@Frederick:</p>
<p>Matlab has had just-in-time compilation for quite some time (since v6.5), and it is even possible to partially precompile code to a bytecode format through the pcode function.</p>
<p>Newer versions have both classes and modules, and should be comparable to Python when it comes to code base organization.</p>
<p>IMHO, the real problem with Matlab is that there is some old legacy cruft which still enables people to &#8220;code FORTRAN&#8221; in it, and which Mathworks are reluctant to deprecate, in order to maintain backwards compatibility. </p>
<p>A &#8220;cleansed&#8221; version would be preferrable, and would probably feel a lot like Scheme with matrices instead of lists.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Rich</title>
		<link>http://www.programming4scientists.com/2009/11/17/should-i-switch-to-python/comment-page-1/#comment-441</link>
		<dc:creator>Rich</dc:creator>
		<pubDate>Wed, 18 Nov 2009 11:28:03 +0000</pubDate>
		<guid isPermaLink="false">http://www.programming4scientists.com/?p=613#comment-441</guid>
		<description>Hi guys,

Thanks for all your feedback!  This is something I&#039;m genuinely thinking about at the moment, so I&#039;m glad that people have valuable insights to offer.

Jordi -  yes, perhaps I overstated slightly the number of benefits :-)  One additional benefit I should also have mentioned is that I find the syntax of Matlab a little bit counter-intuitive sometimes (for example, the function zeros(4) would generate a 4-by-4 element array, not a 1D array with 4 elements).

I have in mind that I&#039;ll write at least one update post on this subject at a later date, so watch this space!

Frederick - thanks for your comments.  I don&#039;t have any great knowledge of Lisp, so it&#039;s great to have some feedback on that!  

I disagree that OO is a &quot;terrible way to organise mathematical code&quot;.  My experience (which is mainly with statistical modelling) is that the features of OO are pretty useful, for the usual reasons.  I&#039;d be happy to accept that it may not be well suited for all areas of mathematics, and I&#039;d certainly be happy to acknowledge that there are other approaches (such as functional programming) that have a lot of merit.  But I think it&#039;s wrong to imply that there&#039;s no merit to using OO in relation to mathematical code.</description>
		<content:encoded><![CDATA[<p>Hi guys,</p>
<p>Thanks for all your feedback!  This is something I&#8217;m genuinely thinking about at the moment, so I&#8217;m glad that people have valuable insights to offer.</p>
<p>Jordi &#8211;  yes, perhaps I overstated slightly the number of benefits :-)  One additional benefit I should also have mentioned is that I find the syntax of Matlab a little bit counter-intuitive sometimes (for example, the function zeros(4) would generate a 4-by-4 element array, not a 1D array with 4 elements).</p>
<p>I have in mind that I&#8217;ll write at least one update post on this subject at a later date, so watch this space!</p>
<p>Frederick &#8211; thanks for your comments.  I don&#8217;t have any great knowledge of Lisp, so it&#8217;s great to have some feedback on that!  </p>
<p>I disagree that OO is a &#8220;terrible way to organise mathematical code&#8221;.  My experience (which is mainly with statistical modelling) is that the features of OO are pretty useful, for the usual reasons.  I&#8217;d be happy to accept that it may not be well suited for all areas of mathematics, and I&#8217;d certainly be happy to acknowledge that there are other approaches (such as functional programming) that have a lot of merit.  But I think it&#8217;s wrong to imply that there&#8217;s no merit to using OO in relation to mathematical code.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jordi</title>
		<link>http://www.programming4scientists.com/2009/11/17/should-i-switch-to-python/comment-page-1/#comment-440</link>
		<dc:creator>Jordi</dc:creator>
		<pubDate>Wed, 18 Nov 2009 10:53:07 +0000</pubDate>
		<guid isPermaLink="false">http://www.programming4scientists.com/?p=613#comment-440</guid>
		<description>&quot;it’s clear that there are a lot of benefits to be derived from changing to Python&quot;

To be honest I don&#039;t think it&#039;s that clear from this post. You are mainly giving reasons for why Python might be a decent sci language and why it wouldn&#039;t be the worst thing to switch to it from using Matlab. The only benefit in your post that Python has over Matlab is that it&#039;s free. This may be a big benefit, but it is still just one (not &quot;a lot&quot;). (Maybe Python is a little more transferable as well, but that&#039;s still just 2)
I don&#039;t mean to get caught up in semantics here. It&#039;s just that I would be interested in hearing about more of these benefits if they exist.

If Rich does switch, it would be great if the process and comparison between the languages/environments could be documented here.</description>
		<content:encoded><![CDATA[<p>&#8220;it’s clear that there are a lot of benefits to be derived from changing to Python&#8221;</p>
<p>To be honest I don&#8217;t think it&#8217;s that clear from this post. You are mainly giving reasons for why Python might be a decent sci language and why it wouldn&#8217;t be the worst thing to switch to it from using Matlab. The only benefit in your post that Python has over Matlab is that it&#8217;s free. This may be a big benefit, but it is still just one (not &#8220;a lot&#8221;). (Maybe Python is a little more transferable as well, but that&#8217;s still just 2)<br />
I don&#8217;t mean to get caught up in semantics here. It&#8217;s just that I would be interested in hearing about more of these benefits if they exist.</p>
<p>If Rich does switch, it would be great if the process and comparison between the languages/environments could be documented here.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
