Skip to content

Commit

Permalink
Use a smaller propr object to comply with CRAN
Browse files Browse the repository at this point in the history
  • Loading branch information
tpq committed Oct 31, 2016
1 parent 4df8585 commit 5036cad
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions data-raw/toad-data.R
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ caneToad.groups <- caneToad.groups[1,]
# Build propr object
keep <- apply(caneToad.counts, 2, function(x) sum(x >= 10) >= 10)
rho <- perb(caneToad.counts, select = keep)
best.99 <- rho[">", .99]
top <- simplify(best.99)
best.995 <- rho[">", .995]
top <- simplify(best.995)

# Use data
devtools::use_data(caneToad.counts, caneToad.groups, top, overwrite = TRUE)
Binary file modified data/top.rda
Binary file not shown.
6 changes: 3 additions & 3 deletions vignettes/visualize.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,10 @@ The proportionality metric $\rho$ has two advantages compared to $\phi$. First,
rho <- perb(caneToad.counts, select = keep)
```

Next, we index the most highly proportional pairs based on an arbitrary threshold. In the absence of any statistical testing framework, we set this threshold at $\rho>0.99$ to include only "very proportional" transcript pairs. Alternatively, we could set this threshold at $\rho<-0.99$ to include only "very unproportional" pairs.
Next, we index the most highly proportional pairs based on an arbitrary threshold. In the absence of any statistical testing framework, we set this threshold at $\rho>0.99$ to include only "very proportional" transcript pairs. Alternatively, we could set this threshold at $\rho<-0.99$ to include only "very unproportional" pairs. However, take note that we use a more stringent threshold here so that the vignette renders more quickly.

```{r, eval = FALSE}
best <- rho[">", .99]
best <- rho[">", .995]
```

## Index-aware Plots
Expand Down Expand Up @@ -114,7 +114,7 @@ These figures help us conceptualize high-dimensional data and select a highly pr
We can extract cluster 3 from the `propr` object using the `subset` method.

```{r, results = "hide"}
sub <- subset(top, select = (clusts == 3))
sub <- subset(top, select = (clusts == 4))
```

Now, we can use the `mds` and `snapshot` functions to see how well this cluster differentiates the two experimental groups based on unsupervised methods. We see below in the `mds` plot that projecting our samples across this highly proportional module leads to a near perfect separation between the two experimental groups, excepting the samples "RM0010" and "RM0169". This matches the separation achieved in the source publication which used `edgeR` for feature selection (Rollins 2015).
Expand Down

0 comments on commit 5036cad

Please sign in to comment.