I’m a molecular biologist trying to teach myself some bioinformatics. At the moment, I’m using the goseq package to analyse differentially expressed genes in my rnaseq data set. I’m using the function nullp to calculate a probability weighting function. As my genome/geneID is not supported by goseq, I have calculated the gene lengths manually using:
txsByGene=transcriptsBy(txdb,"gene")
lengthData=median(width(txsByGene))
I then input the lengthData vector into:
pwf=nullp(genes,’bosTau6’,ensGene’,bias.data=lengthData)
Error in nullp(genes, "bosTau6", "ensGene", "lengthData") :
bias.data vector must have the same length as DEgenes vector!
I check the lengths of the ‘genes’ and ‘lengthData’ vectors and they are the same i.e 24616. Any ideas why R is reporting that the 2 vectors have different lengths?
lengthData vector:
ENSBTAG00000000005 ENSBTAG00000000008 ENSBTAG00000000009
89702.0 30289.0 2973.0
….
genes vector:
ENSBTAG00000000005 ENSBTAG00000000008 ENSBTAG00000000009
0 0 0
….
Thanks
txsByGene=transcriptsBy(txdb,"gene")
lengthData=median(width(txsByGene))
I then input the lengthData vector into:
pwf=nullp(genes,’bosTau6’,ensGene’,bias.data=lengthData)
Error in nullp(genes, "bosTau6", "ensGene", "lengthData") :
bias.data vector must have the same length as DEgenes vector!
I check the lengths of the ‘genes’ and ‘lengthData’ vectors and they are the same i.e 24616. Any ideas why R is reporting that the 2 vectors have different lengths?
lengthData vector:
ENSBTAG00000000005 ENSBTAG00000000008 ENSBTAG00000000009
89702.0 30289.0 2973.0
….
genes vector:
ENSBTAG00000000005 ENSBTAG00000000008 ENSBTAG00000000009
0 0 0
….
Thanks
Comment