reneshbedre / bioinfokit

Bioinformatics data analysis and visualization toolkit
MIT License
334 stars 77 forks source link

Slightly confusing error message if all are significant #7

Closed kjerstirise closed 4 years ago

kjerstirise commented 4 years ago

This is a very unlikely scenario I know, I just thought it could be useful to let you know. On line 156, the error message says "either significant up or down genes are missing; try to lower lfc_thr or ' \ 'increase pv_thr'" if the number of colours is not three. However, if you for some reason, like I did, have a testfile with only significant values, this message is very confusing. I know it's not close to real data, but i just thought you should know.

reneshbedre commented 4 years ago

Hi @kjerstirise,

Thank you for your concern and for letting me know. The given error message is a just checkpoint to check if your dataset contains any significant differentially expressed genes at certain cutoff (lfc_thr and pv_thr) to color them on the volcano plot. If by any chance, you have provided very high cutoff or your dataset does not have significant differentially expressed genes, you need to adjust this lfc_thr and pv_thr based on your dataset. If you still get this error with your desired lfc_thr and pv_thr cutoff, your dataset is not suitable for the volcano plot. In this case, it will be a regular scatter plot without any differentiation.

Let me know your thoughts if you have any.

kjerstirise commented 4 years ago

Hi, In my case all genes were significant, which is why this error message didn't make any sense. I tend to use the head of my data files as test runs, and didn't think it through this time. But I see your point, and it worked well for my actual data :)

reneshbedre commented 4 years ago

@kjerstirise

It is very unlikely that in a high-throughput gene expression experiments, you will get all genes as statistically significant. You have got it because you have used the first few rows of the data. But, you are right, this error message is misleading for this scenario. I will consider to change it in a future release to accommodate this scenario.

Thank you for your input and for using bioinfokit.

reneshbedre commented 4 years ago

@kjerstirise,

I have fixed this issue in v0.9.3