Skip to content

Commit

Permalink
passing all checks
Browse files Browse the repository at this point in the history
  • Loading branch information
nhejazi committed Feb 23, 2018
1 parent fb64198 commit f94ae06
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: adaptest
Title: Data-adaptive test statistics for multiple testing in high dimensions
Version: 0.8.5
Version: 0.8.6
Authors@R: c(
person("Weixin", "Cai", email = "wcai@berkeley.edu",
role = c("aut", "cre", "cph"),
Expand Down
8 changes: 4 additions & 4 deletions tests/testthat/test-cv_origami.R
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ time_seq <- system.time(
)

if (availableCores() > 1) {
plan(multiprocess)
plan(multicore)
}
set.seed(48915672)
time_mc <- system.time(
Expand All @@ -86,13 +86,13 @@ time_mc <- system.time(
)
)

test_that("Multiprocess and sequential evaluation return identical objects", {
test_that("Multicore and sequential evaluation return identical objects", {
expect_equal(result_seq, result_mc)
})

if (availableCores() > 1) {
test_that("Multiprocess evaluation is faster than sequential evaluation", {
test_that("Multicore evaluation is not much slower than sequential", {
skip_on_os("windows") # Windows doesn't support multicore
expect_lt(time_mc["elapsed"], time_seq["elapsed"])
expect_lt(time_mc["elapsed"], 1.2 * time_seq["elapsed"])
})
}
12 changes: 6 additions & 6 deletions vignettes/differentialExpression.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,8 @@ matrix. We demonstrate the necessary syntax for calling `adaptest` below:
adaptest_out <- adaptest(Y = Y,
A = A,
W = NULL,
n_top = 25,
n_fold = 3,
n_top = 35,
n_fold = 5,
SL_lib = c("SL.glm", "SL.mean"),
parameter_wrapper = adaptest::rank_DE,
absolute = FALSE,
Expand Down Expand Up @@ -139,7 +139,7 @@ object and the popular `airway` data set as an example.

To start, let's load the required packages:

```{r sum_exp, message=FALSE}
```{r sum_exp, message=FALSE, eval=FALSE}
library(SummarizedExperiment)
library(airway)
data(airway)
Expand All @@ -148,7 +148,7 @@ data(airway)
For simplicity, we'll restrict ourselves to just a random subset of the genes or
transcripts available from the _airway_ data set.

```{r}
```{r augment_se, eval=FALSE}
genes_sub <- order(sample(seq_len(1000)))
air_reduced <- airway[genes_sub, ]
```
Expand All @@ -158,15 +158,15 @@ data-intensive procedure, requiring a fairly large sample size. To work with the
relatively small `airway` data set, we'll simply augment the data by doubling it
in size in a naive manner:

```{r augment_airway}
```{r augment_airway, eval=FALSE}
simple_air <- cbind(air_reduced, air_reduced)
```

Now, we can perform the same data-adaptive analysis we discussed above on this
simplified version of the _airway_ data set, simply by calling the `bioadaptest`
wrapper function:

```{r}
```{r bioadaptest, eval=FALSE}
airway_out <- bioadaptest(data_in = simple_air,
var_int = as.matrix(colData(simple_air))[, 3],
cntrl_set = NULL,
Expand Down

0 comments on commit f94ae06

Please sign in to comment.