-3

I have drawn heat maps from microarray expression data set and in the heatmaps I see duplicates and triplicates for many of the genes I am interested

I am very new to R and is there a way to remove these duplicates or triplicates of genes

For example I see name of one gene say (BMP1) 2 or 3 times in the heatmap

Kindly suggest me with some solutions

Regards Ram

  • 8
    Where is the [reproducible example](http://stackoverflow.com/questions/5963269/how-to-make-a-great-r-reproducible-example)? –  Aug 11 '14 at 08:13
  • 1
    Which one of the two or three hits do you want to *remove*? – Beasterfield Aug 11 '14 at 08:27
  • Data set made from GEO database ILMN_gene and from this object i filtered my genes of interest notch genes and neural genes notchGenesIndex<- which(ILMN_gene %in% NotchNNeural_Genes[,1]) neuralGenesIndex <- which(ILMN_gene %in% NotchNNeural_Genes[,2] ) and after this I get around 80-90 genes retrieved for each index which include duplicates for my actual genes of interest which are around 45-50. Hope I make sense – user3928779 Aug 11 '14 at 08:39

1 Answers1

0

I try to guess your answer, but it will be better if you give an example of your problem:

> tmp <- data.frame("numbers" = 1:3, "letters" = letters[1:3])
> tmp
  numbers letters
1       1       a
2       2       b
3       3       c
> tmp <- rbind(tmp,tmp)
> tmp
  numbers letters
1       1       a
2       2       b
3       3       c
4       1       a
5       2       b
6       3       c
> unique(tmp)
  numbers letters
1       1       a
2       2       b
3       3       c

From the base help unique returns a vector, data frame or array like x but with duplicate elements/rows removed.

BBrill
  • 1,922
  • 17
  • 17
  • I have an expression dataset with around 47000 rows corresponding to various genes and their replicate probes (duplicate or triplicates). I try to find genes of my interest (around 48) in the expression dataset and I get 80-90 results which are replicates for my genes of interest. Now I want to remove these replicate probes and consider only 48 values for my genes of interest. As I am new to stackoverflow I am unable to attach my heatmaps – user3928779 Aug 11 '14 at 10:11
  • I have made an index of genes of my interest and located this index in exprsn dataset. For example, if one of the genes of interest in the index I made is BMP1 I am getting two or three BMP1 gene values in the heatmap I made in further steps – user3928779 Aug 11 '14 at 10:15