I have a tab separated data text file (Data.txt) with 13 columns and 90 rows. It has a header row (sample values) and the 1st column is sample names.
When I load my data into a data matrix my 1st column sample names don't show. They are all replaced with NA. I believe this causes the sample names not to show up as column labels on the heatmap.
Here is my simple script:
library(gplots)
y <- data.matrix(Data)
heatmap.2(y, main=K12_Ancient_Calculator, trace="none",
margins = c(10,12), cexRow=0.5)
Any ideas what needs to be done so that the sample names in the 1st column of my data file show up in y (data matrix). Currently they show up as NA.
I have noticed that in my version of Rstudio there is no option to declare 1st column of data file as "labels" when using the "import dataset" feature.
All feedback greatly appreciated.