From 30edfa28af01f4600a86a5c5db36e5eb975b3d21 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 4 Feb 2026 17:51:24 +0000 Subject: [PATCH 1/3] Initial plan From 295b6c59f817cf31a80dfdf8350747b13fa93c09 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 4 Feb 2026 17:52:55 +0000 Subject: [PATCH 2/3] Replace deprecated add_rownames() with rownames_to_column() Co-authored-by: Ulthran <14882396+Ulthran@users.noreply.github.com> --- DESCRIPTION | 3 ++- vignettes/zibr.Rmd | 9 +++++---- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index 6303627..f1021b1 100755 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -20,7 +20,8 @@ Suggests: nlme, knitr, rmarkdown, - testthat (>= 3.0.0) + testthat (>= 3.0.0), + tibble Config/testthat/edition: 3 Depends: R (>= 2.10), diff --git a/vignettes/zibr.Rmd b/vignettes/zibr.Rmd index cafcc67..c1bfed5 100755 --- a/vignettes/zibr.Rmd +++ b/vignettes/zibr.Rmd @@ -18,6 +18,7 @@ knitr::opts_chunk$set( library(ZIBR) library(dplyr) library(nlme) +library(tibble) set.seed(19683) ``` @@ -171,14 +172,14 @@ sample.info <- read.csv(sample.info.file, row.names = 1) #### Time, antiTNF+EEN reg.cov <- data.frame(Sample = rownames(taxa.data), stringsAsFactors = FALSE) %>% - left_join(add_rownames(sample.info, var = "Sample"), by = "Sample") %>% + left_join(rownames_to_column(sample.info, var = "Sample"), by = "Sample") %>% dplyr::filter(Treatment.Specific != "PEN") %>% dplyr::select(Sample, Time, Subject, Response, Treatment.Specific) %>% group_by(Subject) %>% summarise(count = n()) %>% dplyr::filter(count == 4) %>% dplyr::select(Subject) %>% - left_join(add_rownames(sample.info, var = "Sample"), by = "Subject") %>% + left_join(rownames_to_column(sample.info, var = "Sample"), by = "Subject") %>% mutate(Treat = ifelse(Treatment.Specific == "antiTNF", 1, 0)) %>% dplyr::select(Sample, Subject, Time, Response, Treat) %>% dplyr::mutate(Subject = paste("S", Subject, sep = "")) %>% @@ -246,14 +247,14 @@ for (spe in spe.all) { #### adjust p values p.species.zibr <- t(as.data.frame(p.species.list.zibr)) p.species.zibr.adj <- - add_rownames(as.data.frame(p.species.zibr), var = "Species") %>% mutate_each(funs(p.adjust(., "fdr")), -Species) + rownames_to_column(as.data.frame(p.species.zibr), var = "Species") %>% mutate_each(funs(p.adjust(., "fdr")), -Species) # write.csv(p.species.zibr.adj,file=paste('4_Results/Real_Data_Estimation_Results_antiTNF_EEN_ZIBR.csv',sep='')) p.species.lme <- t(as.data.frame(p.species.list.lme)) p.species.lme.adj <- - add_rownames(as.data.frame(p.species.lme), var = "Species") %>% mutate_each(funs(p.adjust(., "fdr")), -Species) + rownames_to_column(as.data.frame(p.species.lme), var = "Species") %>% mutate_each(funs(p.adjust(., "fdr")), -Species) # write.csv(p.species.lme.adj,file=paste('4_Results/Real_Data_Estimation_Results_antiTNF_EEN_LME.csv',sep='')) From 7ec0ac14cb1e59784afcb55a2c7ea21d01a3f4b9 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 4 Feb 2026 20:46:23 +0000 Subject: [PATCH 3/3] Replace deprecated mutate_each() with mutate(across()) Co-authored-by: Ulthran <14882396+Ulthran@users.noreply.github.com> --- vignettes/zibr.Rmd | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/vignettes/zibr.Rmd b/vignettes/zibr.Rmd index c1bfed5..876f038 100755 --- a/vignettes/zibr.Rmd +++ b/vignettes/zibr.Rmd @@ -247,14 +247,14 @@ for (spe in spe.all) { #### adjust p values p.species.zibr <- t(as.data.frame(p.species.list.zibr)) p.species.zibr.adj <- - rownames_to_column(as.data.frame(p.species.zibr), var = "Species") %>% mutate_each(funs(p.adjust(., "fdr")), -Species) + rownames_to_column(as.data.frame(p.species.zibr), var = "Species") %>% mutate(across(-Species, ~p.adjust(., "fdr"))) # write.csv(p.species.zibr.adj,file=paste('4_Results/Real_Data_Estimation_Results_antiTNF_EEN_ZIBR.csv',sep='')) p.species.lme <- t(as.data.frame(p.species.list.lme)) p.species.lme.adj <- - rownames_to_column(as.data.frame(p.species.lme), var = "Species") %>% mutate_each(funs(p.adjust(., "fdr")), -Species) + rownames_to_column(as.data.frame(p.species.lme), var = "Species") %>% mutate(across(-Species, ~p.adjust(., "fdr"))) # write.csv(p.species.lme.adj,file=paste('4_Results/Real_Data_Estimation_Results_antiTNF_EEN_LME.csv',sep=''))