0
$\begingroup$

I'm currently learning to acquire images using confocal microscopy and subsequently analyze the images using the Fiji software. I want to know how and where exactly Python or MATLAB is used by practising cell biologists and microscopists for image analysis and learning which language might be beneficial. Thanks in advance!

$\endgroup$
5
  • 2
    $\begingroup$ Fiji is Java based, it is a modified version of the NIH ImageJ...so Java... $\endgroup$
    – bob1
    Jan 31, 2023 at 19:00
  • 4
    $\begingroup$ This is really not a question about a problem in biology. You might try SE Bioinformatics, but cut the stuff about prerequisites for learning different programming languages, which is certainly a separate question (and one I would judge to be off-topic). $\endgroup$
    – David
    Jan 31, 2023 at 22:38
  • 1
    $\begingroup$ I agree that the first part of this question is off-topic here, and the second part is probably off-topic on most Stack Exchange sites. That being said, speaking from experience as a Python programmer, that language is not only pretty straight-forward to learn (never used Matlab, so can't speak to that), but it also has tons of 3rd party modules available for image processing, recognition, and analysis, both for general use and some specifically for working with microscopy data. Python also benefits from having a huge developer and user base, and it's open-source, which Matlab is not. $\endgroup$
    – MattDMo
    Feb 1, 2023 at 17:31
  • $\begingroup$ @MattDMo — Please do not make statements like "Python is very easy to learn". That is completely subjective, and depends on whether you have already learned programming in some other language. That is one of the reasons why, as you acknowledge, the question is off-topic. $\endgroup$
    – David
    Feb 2, 2023 at 9:35
  • 3
    $\begingroup$ @David Please don't take what I said out of context, and please accurately represent what I said. I purposely did not say that "Python is very easy to learn" because it isn't, necessarily, especially if you've never programmed before or if you're coming from a completely different paradigm. I said "speaking from experience as a Python programmer, that language is [...] pretty straight-forward to learn". The language is clean and straight-forward, as computer languages go, in that it isn't overly convoluted or cryptic. $\endgroup$
    – MattDMo
    Feb 2, 2023 at 12:09

1 Answer 1

0
$\begingroup$

I can't speak for MATLAB, but:

Why it's good to know Python:

Python Ecosystem

There is a lot of support for scientific image analysis in Python, as attested by such powerful and heavily maintained packages as scikit-image and opencv. Both are used extensively in biology and other scientific areas. And the vast majority of libraries in Python are free (not so for MATLAB).

Also, there's a huge amount of material freely available online, like tutorials, Q&A's, and more than a few different free IDEs to choose from, for pretty much any operating system you'd like.

Python AI Support

More importantly, most of what's happening in AI these days is image processing, and most of what's happening in AI image processing these days is implemented in Python (at least at the top level). So, whenever you think machine learning might be a good fit for your application, most likely Python will be as well.

Yes, it is true that there are bindings for a lot of other languages, including MATLAB (and Java, and R...), but those aren't typically native to the ecosystems and they won't be as well supported.

Python General Purpose Programming

I believe the most important argument for Python and against MATLAB and R is that Python is a general-purpose programming language. It has excellent support for image analysis and statistics (arguably not worse than MATLAB and R), but it also makes it easy to do what is needed to actually use your solutions in practice, like file system operations, data base access, user interfaces, and microscope control: It's not enough to have a great algorithm for finding nuclei in an image, you also want to be able to apply that algorithm to a slew of images you download from somewhere on the fly or acquire using an automated microscope or camera.

Oh, and you'll be much more likely to apply your programming skills in Python than in MATLAB outside of research.

Where is Python Used?

Python is used wherever the above arguments are important. That means that Python is used in biology wherever:

  • image analysis is important, but
  • the job is more than just plain image analysis, and especially
  • wherever AI/machine learning is a good fit.

I would even go as far as saying that Python is simply more modern than MATLAB, and wherever people are free to choose, they tend to go for Python.

(That said, MATLAB and R have a long track record and a huge following in all the sciences and they're still very well used.)

$\endgroup$
2
  • 1
    $\begingroup$ I would not really compare MATLAB and R. The main knock against matlab is that it's proprietary subscription software, and a costly subscription at that. As such, many academics avoid it (I'm one of the ones who doesn't and uses MATLAB extensively). R is the premier language for statistical software at the research level; almost everything available in Python was first available in R until someone ported it there. I also use R extensively. They do very different jobs. $\endgroup$
    – Bryan Krause
    Jan 19 at 15:00
  • $\begingroup$ I agree that MATLAB and R have a different focus. But they're often (ab)used for the same purposes. You can do image analysis in R, although that's not necessarily one of its strengths, and you can do statistics in MATLAB, although R has much better support for that. The choice of tool is very often determined by what people and their communities are used to rather than the specific strengths of the tools. And as an arrogant Python developer, I'd argue that there isn't much nowadays that MATLAB or R have that Python doesn't. $\endgroup$ Jan 19 at 15:38

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .