From 98760d25dbb78ed8440b34841c89d0d1a6aaa990 Mon Sep 17 00:00:00 2001 From: Tuomas Borman <60338854+TuomasBorman@users.noreply.github.com> Date: Mon, 2 Oct 2023 17:57:30 +0300 Subject: [PATCH] Disable miaTime chunks in vignette (#97) * up * up --- DESCRIPTION | 3 +-- tests/testthat/test-2plotSeries.R | 2 +- vignettes/miaViz.Rmd | 12 ++++++------ 3 files changed, 8 insertions(+), 9 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index f35c3dae..394b43fb 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -60,8 +60,7 @@ Suggests: patchwork, vegan, microbiomeDataSets, - bluster, - miaTime + bluster Roxygen: list(markdown = TRUE) RoxygenNote: 7.2.3 VignetteBuilder: knitr diff --git a/tests/testthat/test-2plotSeries.R b/tests/testthat/test-2plotSeries.R index 817e3a03..b509ae04 100644 --- a/tests/testthat/test-2plotSeries.R +++ b/tests/testthat/test-2plotSeries.R @@ -4,7 +4,7 @@ test_that("plot series", { # Load data from miaTime package if( !require("miaTime") ){ if( !require("devtools") ){ - install.packages("devtools") + BiocManager::install("devtools") } devtools::install_github("microbiome/miaTime") library("miaTime") diff --git a/vignettes/miaViz.Rmd b/vignettes/miaViz.Rmd index 99b0dc2c..7a599d46 100644 --- a/vignettes/miaViz.Rmd +++ b/vignettes/miaViz.Rmd @@ -329,7 +329,7 @@ plotDMNFit(dmn_se, type = "laplace") # Serial data ordination and trajectories -```{r, error=FALSE, warning=FALSE, results='hide'} +```{r, eval=FALSE} if(!requireNamespace("devtools", quietly = TRUE)){ BiocManager::install("devtools") } @@ -341,7 +341,7 @@ if(!requireNamespace("miaTime", quietly = TRUE)){ Principal Coordinates Analysis using Bray-Curtis dissimilarity on the `hitchip1006` dataset: -```{r MDS, include=FALSE} +```{r MDS, eval=FALSE} library(miaTime) data(hitchip1006, package = "miaTime") tse <- hitchip1006 @@ -356,7 +356,7 @@ p Retrieving information about all available trajectories: -```{r} +```{r, eval=FALSE} library(dplyr) # List subjects with two time points @@ -369,7 +369,7 @@ table(table(tse$subject)) %>% as.data.frame() %>% Lets look at all trajectories having two time points in the data: -```{r} +```{r, eval=FALSE} # plot p + geom_path(aes(x=X1, y=X2, group=subject), arrow=arrow(length = unit(0.1, "inches")), @@ -383,7 +383,7 @@ p + geom_path(aes(x=X1, y=X2, group=subject), Filtering the two time point trajectories by divergence and displaying top 10%: -```{r} +```{r, eval=FALSE} library(miaTime) # calculating step wise divergence based on the microbial profiles tse <- getStepwiseDivergence(tse, group = "subject", time_field = "time") @@ -411,7 +411,7 @@ p + geom_path(aes(x=X1, y=X2, Plotting an example of the trajectory with the maximum total divergence: -```{r} +```{r, eval=FALSE} # Get subject with the maximum total divergence selected.subject <- data.frame(reducedDim(tse), colData(tse)) %>% group_by(subject) %>%