@@ -82,8 +82,7 @@ need for the analysis today: name, cell type, status.
8282``` {r loadSampleInfo, message = FALSE}
8383# Read the sample information into a data frame
8484sampleinfo <- read_tsv("data/samplesheet.tsv", col_types = c("cccc"))
85- sampleinfo %>%
86- arrange(Status, TimePoint, Replicate)
85+ arrange(sampleinfo, Status, TimePoint, Replicate)
8786```
8887
8988## Reading in the count data
@@ -102,9 +101,8 @@ The Salmon quantification results are per transcript, we'll want to summarise
102101to gene level. To this we need a table that relates transcript IDs to gene IDs.
103102
104103``` {r readSalmon}
105- files <- str_c ("salmon/ ", sampleinfo$SampleName, "/ quant.sf")
104+ files <- file.path ("salmon", sampleinfo$SampleName, "quant.sf")
106105files <- set_names(files, sampleinfo$SampleName)
107-
108106tx2gene <- read_tsv("references/tx2gene.tsv")
109107
110108txi <- tximport(files, type = "salmon", tx2gene = tx2gene)
@@ -138,8 +136,7 @@ saveRDS(txi, file = "salmon_outputs/txi.rds")
138136One of the most complex aspects of learning to work with data in ` R ` is
139137getting to grips with subsetting and manipulating data tables. The package
140138` dplyr ` [ @Wickham2018 ] was developed to make this process more intuitive than it
141- is using standard base ` R ` processes. It also makes use of a new symbol ` %>% ` ,
142- called the "pipe", which makes the code a bit tidier.
139+ is using standard base ` R ` processes.
143140
144141In particular we will use the commands:
145142
0 commit comments