I was given the task of generating a heatmap with a dataset but as I entered data into R, it told me I cannot have repeating rows (which would be in my case the genes that are expressed). Does anyone know how I can normalize that data? Thanks
If it just the rownames, make them unique.
Ex: rownames(data)=paste(rep("Row",nrow(data))) or check make.unique function
I tried that make.unique function:
row.names(PDR) <- PDR$Gene.Symbol
Error in `row.names<-.data.frame`(`*tmp*`, value = c(1L, 1L, 1L, 1L, 1L, :
duplicate 'row.names' are not allowed
In addition: Warning message:
non-unique values when setting 'row.names': 'BCL11A', 'BCL2', 'CCL5', 'CCR2', 'EED', 'EZH2',
But this error came up. Trying to have the Gene Symbols appear on the Y axis of the heatmap instead of the numbers. Thanks.
Input to make.unique is a variable containing the names, not a single character value.
Login before adding your answer.
Use of this site constitutes acceptance of our User Agreement and Privacy