Hi,
I am attempting to make some heat maps with some RNA-Seq data. I used Salmon for my quantification and followed this link to import my data into R so I can use Deseq2. So I am just going through the Deseq2 little tutorial here. I am trying to follow their instruction on how to create some heat maps. I believe my issue is with the row names. Someone asked a similar question to mine here but the issue was never resolved. So in that post, it was suggest that the row names were set to the default 1,2,3,4,5,6,7,8, which is true. This is the result I get when I run rownames(df)
[1] "1" "2" "3" "4" "5" "6" "7" "8"
So I trued to change the column names by running the following
rownames(df) <- c("adp1","adp2","adp3","adp4","fed1","fed2","fed3","fed4")
dds@colData@rownames <- c("adp1","adp2","adp3","adp4","fed1","fed2","fed3","fed4")
However, I am still getting the same error
select <- order(rowMeans(counts(dds,normalized=TRUE)),
decreasing=TRUE)[1:20]
df <- as.data.frame(colData(dds)[,c("condition")])
pheatmap(assay(ntd)[select,], cluster_rows=FALSE, show_rownames=FALSE,
cluster_cols=FALSE, annotation_col=df)
Error in check.length("fill") : 'gpar' element 'fill' must not be length 0
I
think my attempts to change the row names were point less? I think the issues goes way back to important my Salmon data into R? I could be mistaken but when I went through their import tutorial, the samples were labeled as sample1, sample2, sample3, etc.
Any help would be amazing!
The only place in R I've seen
@
s used like that are in S4 objects - What is thisdds
object? Is it a custom S4 object?EDIT: Never mind, apparently Bioconductor uses a lot of S4 objects.
I was really thrown off by that as well. It took me awhile how to figure out how to change the rownames in dds