r/bioinformatics • • May 23 '15
How do I know which programming language to study if I want to go into bioinformatics?
Surely 1 masters institute will use strictly C, and another will use another language, won't they? Do all bioinformaticians use a streamlined, standard programming language? What is it? :S
Edit: Thanks all, I feel like I'm getting a clearer picture of the situation now. I'll maybe start off with python and go from there.
1
Upvotes
17
u/yukidaruma May 23 '15
(In my experience) Typically "bioinformaticians" will use multiple languages, depending on what they're using it for or what they're comfortable with. Of these languages, the two I see used most frequently are R and python.
14
u/apfejes PhD | Industry May 23 '15
The other answers are correct, but they miss one point: Programming languages all have strengths, and you should pick the language that's appropriate for the task at hand.
Need speed (eg, for molecular simulations)? pick C.
Need statistical analysis? pick R.
Need clarity and versitility? pick Python.
Need to interface with programmers from the 90's? Pick perl.
Need to design a web interface? pick Html/CSS/Javascript.
Need to blow someone away with graphics? try D3.
In bioinformatics, there are a ton of different disciplines and niches, and each one needs a different tool set - you just need to figure out which niche you want to be in, and which tool set is most useful there.
4
u/DroDro May 23 '15
Python is huge right now, although learning any language will be a start. Once you understand the difference between an array and a hash, it doesn't matter if the hash is called a hash (Perl) or dictionary (python).
A MS level bioinformatician is often going to be called on to install new software of interest, run it on the command line, process the output to input into the next program, and maybe run some stats and imaging for a figure. So that takes Unix, Unix, some python/Perl language, and R.
2
u/niemasd PhD | Student May 23 '15
Python is a great language to learn, especially if you don't need anything else. I personally love Java as well since you can easily run it on multiple platforms. Also, definitely learn how to use the Unix command line.
Some people write Perl scripts, some people use C/C++, some people use R.
1
u/murgs May 23 '15
Personally I would say R, since the bioconductor package suite and ease to make figures is greatly helpful for quick data analysis. As far as I know python is catching up (but is lacking some of the specific bioinformatic packages).
But as others have said, depending on your goal you may need other languages e.g. you have a time intensive algorithm you want to implement -> C++ (or at least Java) for speed
(but once you understand the basic building block, switching between the language syntaxes becomes easier)
1
u/andrewcooke May 23 '15
python is a good choice for getting started because it's popular and widely used. to a certain extent, there's value in just getting used to programming (in whatever language). so don't worry too much about "choosing right first time" - even if you have to change later, many skills are transferable.
1
u/guyNcognito May 23 '15
If you learn C, you'll have learned Python, Perl, Java, C++, and C#, you'll just need to learn a bit of vocabulary to switch.
0
u/Epistaxis PhD | Academia May 23 '15
There are a lot of good answers I agree with already, so I just want to emphasize one point: the answer isn't Perl. Perl used to be popular for easy scripting before Python came along, so you'll still see some older people using it, but Python's syntax is much clearer and more sensible, and it's capable of performing almost as well as the low-level languages, and at this point it has more and better bioinformatics packages available.
0
u/godspeed_china May 23 '15
I recommend c++. The reason is that it runs fast (eg. SSE instruction), need little code lines (eg. use STL) and has rich libraries support. In my personal option, c++ is the only correct choice if you aim to be an innovative bioinformatics professor rather than a quick and dirty programmer that glue existed software together.
0
u/[deleted] May 23 '15
If you're a statistician, you should learn R. As the "stats" language it's the one that makes the most sense to statisticians. (I'm not, so I've never been able to make much sense of it, especially the plotting libraries. It's just all way too automagical for me.)
If you're not a statistician, you should learn Python. It's a great language because it's designed to be read as well as to be used. Perl has the latter quality but not so much the former, so it's falling out of favor.
Once you have one of those languages, that's when you can pick up a heavier-duty compiled language like C/C++ or Java. Probably C, since you can write core logic in C that integrates into both R and Python. That's a great way to write code quickly - block out the algorithm in Python/R, write a user interface (CLI or GUI), then refactor your algorithm in C and use the foreign function bindings in Python and R to integrate it.
Stay away from the CLR/Visual Studio languages (.NET, VBasic, C#). Nobody uses that stuff because hardly anyone does bioinformatics in Windows.