meringlab / FlashWeave.jl

Inference of microbial interaction networks from large-scale heterogeneous abundance data
Other
70 stars 8 forks source link

why not a flashWeave R package? #38

Open Gian77 opened 3 months ago

Gian77 commented 3 months ago

Just as a curiosity, why this cool tool has been implemented in Julia? Thanks, Gian

jtackm commented 3 months ago

FlashWeave requires many custom algorithms that need to be both really fast and maintainable. We started out in python, but quickly realized that cython/numba were too much overhead or too unrealiable for our needs. I suspect R (with Rcpp) would have caused similar issues. Julia made development of a package like this much easier: being able to code in just one dynamic language with nice generics while still generating fast code.

Regarding running FlashWeave from R: I've seen people using it with JuliaCall (https://hwborchers.github.io/). Perhaps that would work for you? It also shouldn't be hard to make a proper R package (using this interoperability), but I'm not deep in the R ecosphere, so would best leave such a project to somebody with previous experience.

Gian77 commented 3 months ago

Hi @jtackm, thank for your answer and motivations. I understand. I just fell like much more microbial ecologists will have access to it if implemented in a different, more commonly used, lenguage for biologists. Although I am quite good in R, I don't know Julia or C++, but I will for sure look into JuliaCall.

jtackm commented 3 months ago

Yes, I agree it would be great to have FlashWeave also available as native R or Python packages. I'm a bit strained on time currently, but happy to support such efforts if anybody is willing to look into making such wrappers.

In the meantime, the commands are hopefully simple enough and the language close enough to Python/R such that it shouldn't be too much overhead.

shanptom commented 1 month ago

Hi,

The R package: MicroEco allows to call FlashWeave from R. I just started exploring both MicroEco and FlashWeave, so I am not sure is there any drawbacks.

Best,

Shan

jtackm commented 1 month ago

Thanks, I wasn't aware of that. If MicroEco is feature-complete enough, I'd be happy to list that as an option on the main page.