################################################### ### chunk number 1: ################################################### #line 51 "vignettes/Rsubread/inst/doc/Rsubread.Rnw" library(Rsubread) ref <- system.file("extdata","reference.fa",package="Rsubread") path <- system.file("extdata",package="Rsubread") buildindex(basename=file.path(path,"reference_index"),reference=ref) ################################################### ### chunk number 2: ################################################### #line 75 "vignettes/Rsubread/inst/doc/Rsubread.Rnw" reads <- system.file("extdata","reads.txt",package="Rsubread") align(index=file.path(path,"reference_index"),readfile1=reads,output_file=file.path(path,"alignResults.SAM")) ################################################### ### chunk number 3: ################################################### #line 105 "vignettes/Rsubread/inst/doc/Rsubread.Rnw" library(Rsubread) reads <- system.file("extdata","reads.txt",package="Rsubread") x <- qualityScores(filename=reads,nreads=1000) boxplot(x) ################################################### ### chunk number 4: ################################################### #line 116 "vignettes/Rsubread/inst/doc/Rsubread.Rnw" library(Rsubread) reads <- system.file("extdata","reads.txt",package="Rsubread") ## Fraction of A,T,G and C in the entire dataset x <- atgcContent(filename=reads,basewise=FALSE) ## Fraction of A,T,G and C at each base location across all the reads xb <- atgcContent(filename=reads,basewise=TRUE) ################################################### ### chunk number 5: ################################################### #line 130 "vignettes/Rsubread/inst/doc/Rsubread.Rnw" library(Rsubread) results <- system.file("extdata","alignResults.SAM",package="Rsubread") propmapped(results)