dancoster / DrugLab

Repository for the drug<>lab pair
1 stars 0 forks source link

Varitation in drug admistration parameter #50

Open dancoster opened 3 months ago

dancoster commented 3 months ago
  1. Explore what what is the variation of administration type (PO, IV, drips etc.) of each drug. Is there any variation?
  2. Explore what what is the variation of dosage? Is there any variation?

Box Plot (X-Axis: PO, IV, Drips, Y-axis: Ratio, P-value per each administration types).

dancoster commented 2 months ago

[1] Per each sig. pair of varied-admitted drug, please show the effect of different admistarition.

dancoster commented 2 months ago

[1] Boxplot figure (specific pair): (A) flip axis (B) per each group write size (n) and p-value (C) and ration (D) add title+parametrs of function (before = 4h, after=6h)

rfeinsod commented 1 month ago

We want to generate adataframe that the first column is a pair, second administration type, third - num of instances, fourth - pvalue of the pair per administration type.

dancoster commented 1 month ago

There is a bug with the p-values (all are NaN or 1). Additionally, please notice that it will be easier for us to analyze it with a data frame (and not multiple plots). Can you please generate this dataframe?

rfeinsod commented 1 month ago

plots_different_admin.zip

dancoster commented 4 weeks ago

Thx, how did you select these pairs?

rfeinsod commented 3 weeks ago

These are all the pairs with a Bonferroni corrected pvalue under 0.05

dancoster commented 3 weeks ago

mmm I think there is a mistake here, some known pairs are misiing

rfeinsod commented 3 weeks ago

Do you have a specific example?

rfeinsod commented 3 weeks ago

Okay, all missing pairs are pairs where there is only one administration type. I can generate plots for them but the plots wouldn't show anything meaningful.

dancoster commented 3 weeks ago

ok, let's try to generate similar boxplot per each significant pair, but now stratify on the dosage of the administered drug.

dancoster commented 3 weeks ago
rfeinsod commented 2 weeks ago

Dosage stratified.zip

dancoster commented 2 weeks ago
rfeinsod commented 1 week ago

Will continue working on the rest

Image

dancoster commented 1 week ago

Looks better, a few minor comments:

rfeinsod commented 1 week ago

The Pvalue of the title is after the Bonferroni correction. I'm adding some examples now and will re-send all soon after additional changes. To stratify the bins I used pd.qcut to create quantile bins and then split the dataframe accordingly

Image

Image

Image

Image

rfeinsod commented 1 week ago

Take only 3 digits after dot in each p-value -Done Put all in different color - Done Add to the X-axis tick the Mean-+ STD of the ratio of each group - Done Why does all p-value and the p-value in the title are different? - Explained what's the name of algorithm that you were used to stratify the groups? - Explained add also units to the title - Done Add table per pair with the percentage of patients that were removed because of units inalignment. - Done Add p-values that compare the distribution between boxplots. - Done, they don't look, will fix Please add some more examples - Done

Image

Image

Image

Image

dancoster commented 1 week ago

[1] Do you use the full dataset here? (or only 10,000 patients) [2] Please extract only box plots with sig. difference [3] Please make one color for 'all', and the same color to all the groups [4] Changetd to: image [5] Please extract a table with all the pairs which contain patients that were removed due to unit mismatch, and per each pair report the percentage [6] Please extract examples with sig. p-value between boxplots (like piggyback<>Potassium) What did you mean by "Add p-values that compare the distribution between boxplots. - Done, they don't look, will fix" [7] Please generate the similar plot but now stratify of administration type

dancoster commented 1 week ago
rfeinsod commented 1 week ago

1) The Full dataset 2) Ok, Examples Attached 3) OK 4) OK 5)Attached

removals.csv

Image Image Image Image Image Image Image Image

dancoster commented 1 week ago

[5]Adjust 'removals.csv' -(a) calculate p-value per each pair on all samples, (b) calc p-value only of samples with the major type of units (c) add column if there are multiple admistration types per this drug (1/0) (d) calculate the f0ld-change (ratio) between the two types of p-value. [8] Fix title issue and upload updated tables.