Thursday, 25 May 2017

Problem copying figures & tab limited files out of R

To copy a figure 

>dev.copy(pdf,"xxx.pdf")
>dev.off()

the pdf can be modified for any other formats too (png, bmp, jpg)

To copy/write table

write.table(file_name,"/PATH/TO/OUTPUT/file.txt",sep="\t")

Hisat2-Ballgown-running error

bg_chrX=ballgown(dataDir="ballgown",samplePattern="xx",pData=pheno_data


The following error can be solved by
check your .csv file when read csv - The order of the samples mentioned must be the same as the order of the samples in the Ballgown folder

Now it will run without any errors

Tuesday, 16 May 2017

HiSat2 _ R package loading errors

  • Error running 
>pheno_data=read.csv("xxx.csv")

place the xxx.csv file in the R bin or wherever R is being executed from


  • Error running
>click=ballgown(dataDir=...,samplePattern="...",pData=pheno_data)

run the following before running this command

setwd("/PATH/TO/LIBRARY/") - this path should lead R to identify ballgown, where ballgown is in the folder LIBRARY

  • R package 3.4 or other version opens up by default
Download the R-3.2.2 compatible for Hisat2 and run it by routing into the folder R > execute R from its folder and not home directly.