In the field of bioinformatics, who is more powerful and easy to use, and represents the future development direction of python and perl?

Source: Internet
Author: User
Tags perl script learn perl
Php Chinese network (www.php.cn) provides the most comprehensive basic tutorial on programming technology, introducing HTML, CSS, Javascript, Python, Java, Ruby, C, PHP, basic knowledge of MySQL and other programming languages. At the same time, this site also provides a large number of online instances, through which you can better learn programming... Reply content: laxatives.
  1. First, my personal claim is: python!
  2. Three years of experience in biological information application development and data analysis show that it is very efficient for me to select Python and recommend colleagues and friends around me to try and select python, at least obviously overcome some of the drawbacks of perl in the past.
  3. The empty language competition is a violation of professional ethics in procedural ape, but in a special scenario, it may be helpful for new users to think about it. For biological information, language is actually a secondary issue. The most important thing is modeling and solving, rather than tool selection. In addition, sometimes when using other people's programs, you cannot select a language.
  4. Specifically, the python code itself is easier to read and understand than perl, which is basically not too controversial. for non-disposable programs, especially the pipeline class, there are higher requirements for "easy to change". We do not want a lengthy perl script to be unreadable after three months... There are also some weird symbols that can shock people> = <another aspect, for historical reasons, the previously accumulated bioinformatics databases and open source/public programs (for some reason, everyone just shares their own programs without any open-source licenses) most of them are built in perl, and later people continue to learn perl to learn and reproduce. but in fact this is not necessary, you do not need to use perl for this purpose. In practice, people have limited energy and learning a language is easier than learning two languages.
  5. BioXXX is similar, but the community activity is different. At least I have seen and used many programs and analysis processes. perl is mainly used for small scripts. python is often used for pipeline concatenation and some analysis methods, R is mainly used for statistics and result visualization (with bioconductor). as for SVG output, it is basically language-independent, depending on their preferences. Other web tools, such as workbench, are not a few built based on java. for example, some solid tools, CLC workbench, seem to be SWT? And so on. Even Broad's IGV browser uses the java web start technology (rarely seen). maybe it can consider javaFX in the next version ?!
In summary, perl and python have their own advantages and disadvantages. to learn and reproduce previous achievements, Learning perl is understandable. to develop and analyze data in practice, we recommend python first.

By the way, we recommend that you discuss it with others for reference:
  • Http://biostar.stackexchange.com/questions/2742/perl-or-python-for-comparative-genomics
  • Http://network.nature.com/groups/bioinformatics/forum/topics/1611
  • Http://www.quora.com/Bioinformatics/How-did-Perl-start-off-as-the-dominant-language-in-bioinformatics
As I have used two languages, python is indeed the first choice for writing script programs, elegant and easy to understand. However, one reason why I can't keep perl any longer is its powerful ability to process text, because most of the biological information analysis work involves various formats conversion and text processing, perl is powerful enough to use a single line of command to complete the tasks of dozens of python scripts, and it is similar to writing shell command lines, but it can be better than shell command lines, in addition, because these tasks are generally used only once, there is no maintenance or non-maintenance problem, but it is very time-and effort-saving to write with perl. Therefore, I usually use python for writing large programs, and perl for other text processing tasks.
The following is a good tutorial to teach perl single-line commands and learn to benefit a lot.
Http://www.catonmat.net/blog/introduction-to-perl-one-liners/ There is no difference in the language itself, but in general, python is more powerful. On the one hand, google is supported, and more people are using it. on the other hand, python features are richer, you can do text processing, statistical analysis, or even plotting. you can only do text processing for perl, and R for statistics and plotting. The battle for PERL and PYTHON has a long history. Paste it here to see what I have collected. what do you say?

The comparison and debate between perl and Python on biological information has been a long history. here I only provide a few links:

Bioinformatics: Python or Perl?
Powerful and easy-to-learn programming language Python _ has a blog
Could you kindly advise: is it better to learn perl or python for bioinformatics applications?
Recommended Python for learning biological information


In 2013, I conducted a survey on this issue in PERL and Python at the China Unix Forum. now there are many people involved, about 2014 + 200 people at the end of 150, you can also refer:

Perl Usage Survey on Python -Python-ChinaUnix.netPython version

Perl Usage Survey on Python -Perl-ChinaUnix.netPerl

The Perl interface is a huge set of shi: it forces you to write interfaces in the same language as PerlXS, and the API name is also a set of shi.
After reading the Python interface writing method, it seems much cleaner.

==============================

Recently, I wrote a simple code generator using Python to learn Python. It seems that Python has a lot of inconvenience compared with Perl in building Daily scripts:
  • There can be only one statement in labmda. For sorting and ing that is a little troublesome (but not so troublesome), you have to open a single function, rather than simply put it here.

  • Regular expressions are not as easy to use as Perl. For example, Perl can be written as follows:

$foo =~ /Some(Reg)Exp/ or die "failed to parse foo for XXX";my $wanted_part = $1;
I have been using perl for 10 years, and I have not found any place that is not necessary for python. the language is a tool and you use it, just like using PC or MAC, different levels of proficiency mean that the language is weak. However, the available open-source packages and update frequency of Python may be slightly faster than that of Perl.
In addition, I personally think that the Python learning curve is relatively gentle. At least I have been familiar with Perl for many years and still cannot write it out... Daniel can take a picture. Perl has little to do with Python and nxin ~ There are no advantages or disadvantages ~ Because we can skip perl and Python learning and directly apply Bioperl and BioPython ~ Doge ~ In addition, when the language is eliminated, we will be old ~ Awk is so old that it is not always very powerful and easy to use ~ Do you need to process so many texts with Java... Sometimes simplicity does not mean elimination, but in a specific situation it means strong ~ For future development ~ Github ~ There is everything on top of the tide ~ Python, you can not only perform experiments, but also directly export industrial-level code. biopython is a good solution, unless any one of the other's advantages will be absorbed in the future, then you don't have to learn it all.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.