Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
thereallda committed May 12, 2024
1 parent 042b459 commit ef3f992
Show file tree
Hide file tree
Showing 7 changed files with 15,004 additions and 76,322 deletions.
25 changes: 13 additions & 12 deletions .Rbuildignore
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
^enONE\.Rproj$
^\.Rproj\.user$
^LICENSE\.md$
^README\.Rmd$
^doc$
^Meta$
^_pkgdown\.yml$
^docs$
^pkgdown$
^\.github$
^vignettes/data$
^data$
^enONE\.Rproj$
^\.Rproj\.user$
^LICENSE\.md$
^README\.Rmd$
^doc$
^Meta$
^_pkgdown\.yml$
^docs$
^pkgdown$
^cran-comments.md$
^\.github$
^vignettes/data$
^data$
8 changes: 6 additions & 2 deletions .github/workflows/rhub.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,14 @@ jobs:
with:
config: ${{ github.event.inputs.config }}
id: rhub-setup


- uses: r-lib/actions/setup-r@v2
with:
use-public-rspm: true

- uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: any::pkgdown, local::., any::rcmdcheck, any::XML
extra-packages: local::., any::rcmdcheck, any::XML
needs: website

- name: Install dependencies
Expand Down
5 changes: 3 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ Imports:
paintingr,
pbapply,
plotly,
rlang,
rstatix,
S4Vectors,
stats,
Expand All @@ -36,6 +35,8 @@ Imports:
tibble
Suggests:
knitr,
rmarkdown
patchwork,
rmarkdown,
tidyr
VignetteBuilder: knitr
URL: https://thereallda.github.io/enONE/
22 changes: 11 additions & 11 deletions cran-comments.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
## Test environments

- R-hub windows-x86_64-release, R release
- R-hub macos-highsierra-release, R release
- R-hub ubuntu-gcc-release, R release

## R CMD check results

There were no ERRORs, WARNINGs or NOTEs.


## Test environments

- R-hub windows-x86_64-release, R release
- R-hub macos-highsierra-release, R release
- R-hub ubuntu-gcc-release, R release

## R CMD check results

There were no ERRORs, WARNINGs or NOTEs.


91,230 changes: 14,939 additions & 76,291 deletions data/Counts.csv

Large diffs are not rendered by default.

18 changes: 16 additions & 2 deletions vignettes/enONE_tutorial-zh.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,25 @@ knitr::opts_chunk$set(

*Figure: Schematic workflow for total RNAs from PBMCs and three sets of spike-ins.*

通过以下代码下载原始数据。

```{r,warning=FALSE}
# create directory for data
dir.create("data/")
options(timeout = max(6000, getOption("timeout")))
# download Counts.csv
download.file("https://figshare.com/ndownloader/files/46250704", destfile = "data/Counts.csv")
# download metadata.csv
download.file("https://figshare.com/ndownloader/files/46251412", destfile = "data/metadata.csv")
```

我们首先读取数据,包括基因表达量的count matrix和样本信息的metadata。matrix和样本信息的。metadata至少包括两列,即用于样本生物分组的"condition"列和用于样本富集分组的"enrich"列。

```{r,warning=FALSE,message=FALSE}
library(enONE)
library(tidyverse)
library(dplyr)
library(ggplot2)
library(tidyr)
library(patchwork)
# read in metadata and counts matrix
Expand Down Expand Up @@ -339,7 +353,7 @@ syn_level <- synEnrichment(Enone, method=norm.method, log=TRUE)
# transform to long format
syn_df <- as.data.frame(syn_level) %>%
rownames_to_column("syn_id") %>%
tibble::rownames_to_column("syn_id") %>%
pivot_longer(cols = -syn_id,
names_to = "id",
values_to = "logFC") %>%
Expand Down
18 changes: 16 additions & 2 deletions vignettes/enONE_tutorial.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -38,12 +38,26 @@ Notably, we included three types of spike-in RNAs:

*Figure: Schematic workflow for total RNAs from PBMCs and three sets of spike-ins.*

Raw data for this tutorial can be downloaded with the following code.

```{r,warning=FALSE}
# create directory for data
dir.create("data/")
options(timeout = max(6000, getOption("timeout")))
# download Counts.csv
download.file("https://figshare.com/ndownloader/files/46250704", destfile = "data/Counts.csv")
# download metadata.csv
download.file("https://figshare.com/ndownloader/files/46251412", destfile = "data/metadata.csv")
```

We start by reading in the data, including count matrix and metadata. metadata should include at lease two columns, namely the `condition` column for biological grouping of samples, and the `enrich` column for enrichment grouping of samples.


```{r,warning=FALSE,message=FALSE}
library(enONE)
library(tidyverse)
library(dplyr)
library(ggplot2)
library(tidyr)
library(patchwork)
# read in metadata and counts matrix
Expand Down Expand Up @@ -352,7 +366,7 @@ syn_level <- synEnrichment(Enone, method=norm.method, log=TRUE)
# transform to long format
syn_df <- as.data.frame(syn_level) %>%
rownames_to_column("syn_id") %>%
tibble::rownames_to_column("syn_id") %>%
pivot_longer(cols = -syn_id,
names_to = "id",
values_to = "logFC") %>%
Expand Down

0 comments on commit ef3f992

Please sign in to comment.