thegraphnetwork / epigraphhub_py

Epigraphhub Python package
GNU General Public License v3.0
2 stars 9 forks source link

Module to make plots #130

Closed eduardocorrearaujo closed 1 year ago

eduardocorrearaujo commented 2 years ago

🚀 Feature Request

Module to make plots

I think that would be interesting to have a module with functions to make specific plots useful for analyzing health data. If you have some idea of ​​plots, put them here and with time I will work to create the functions to create these plots.

dcpcamara commented 2 years ago

I'm gonna do some bomb dropping / brainstorm on ideas in here. In our 2020 project and for WHO we've made some graphs, maps and tables that can be used for basically any epi situation.

Weekly and/or daily table with some useful epi indicators and descriptive statistics. This can/should be updated depending on the disease we are studying. The following example is for COVID-19: image

Daily and/or weekly epicurve. It seems that general opinion after the COVID-19 pandemic likes this timeseries barplot with a smoothing curve (7-day moving average in the example). This could be done for any important indicator (such as cases, incidence, deaths, mortality, # of tests, # of vaccinated per dose, etc). image image

I kind of like the idea of having a growth-rate graph that can easily indicate the trend of the transmission. We could be making such plots for Rt also, for instance. image

Some mapping could be done for any administrative level. This one is for the whole Africa, but regional mapping can be of great use. I don't know why my work with regional maps was not integrated into this dashboard, but nonetheless, it is something that can be easily done. image

Other graphs that I'm fond of are decomposing timeseries into trend and sazonality (which could be done via curves) and timeseries boxplots - although the general public usually is not very familiar with boxplots.

The above examples are pratically constructed with one or two dimensions at most. Some useful plotting that we can explore can involve three variables, which can be easily done in dispersion plots and maps. I have all these examples in R code if you want to take a look, both in static perspective (e.g., ggplot2) or dynamic/interactive (e.g., plotly). They can be found in the push that Lucas did with some material of the dashboard that we've implement for WHO Afro.

Whew... sorry for the long message.

eduardocorrearaujo commented 2 years ago

Thank you for the answer. I will take a look in this codes. By the way, I think that this code that you and Lucas have can be used to start the epigraphhub R package.

dcpcamara commented 2 years ago

Definitely! However, to my understand the R package would first focus on a translation of the Python package or am I wrong?

xmnlab commented 2 years ago

I thought we will move all R code to a new repo ... that is why it would be good to have it early than later. but maybe I am wrong.

dcpcamara commented 2 years ago

lol maybe we could have a chat with @fccoelho to understand the process better?

fccoelho commented 2 years ago

We can discuss this at our first meeting. But the Idea is that most features should be available on both Languages, therefore it may even mak sense to maintain an integrated documentation with code examples in both languages side-by-side, what do you think?

fccoelho commented 2 years ago

I liked your visualization suggestions @dcpcamara! Perhaps we can do some kind of Documentation-driven development! :-)

fccoelho commented 2 years ago

Regarding the Documentation driven development, I have already created a Joint Documentation repository: https://github.com/thegraphnetwork/epigraphhub-lib-docs So please let's start documenting what is already implemented, and then for every new analysis we need to have the proposal in the documents first and then complement it with examples before merging the PR. @xmnlab @dcpcamara @eduardocorrearaujo

xmnlab commented 2 years ago

that sounds great.

eduardocorrearaujo commented 2 years ago

Ok!

fccoelho commented 2 years ago

I would suggest we work to compensate the weak spots of Superset, namely the visualization of Geo-Reference datasets. We can also think about creating a showcase Streamlit dashboard to demo this visualization module. Welcome @NicoRicardi to our team! feel free to add your own views about this here in this thread.

github-actions[bot] commented 1 year ago

Stale issue message