Skip to content

Commit

Permalink
updated gmt translation using synergizer. In the latest build of ense…
Browse files Browse the repository at this point in the history
…mbl in synergizer uniprot ids have been changed to uniprot_swissprot from uniprot_swissprot_accession
  • Loading branch information
risserlin committed Dec 18, 2015
1 parent 30de1df commit 41efea9
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions GeneSetTools/src/GeneSetTranslator.java
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ public void translate() throws IOException {

//depending on the old ID there are different paths that we can take to maximize coverage
//if uniprot, convert to entrezgene(id1)and symbol(id2)
// try ensembl uniprot_swissprot_accession to entrezgene
// try ensembl uniprot_swissprot to entrezgene
// then ensembl uniprot_sptrembl to entrezgene
// then ncbi uniprot to entrezgene
//
Expand All @@ -122,7 +122,7 @@ public void translate() throws IOException {
if(oldID.equalsIgnoreCase("entrezgene")){
//for each conversion place in oldID to newID into hashmap
id1="UniProt";
conversions_id1.put(1,new SynergizerParams("ensembl", "entrezgene","uniprot_swissprot_accession"));
conversions_id1.put(1,new SynergizerParams("ensembl", "entrezgene","uniprot_swissprot"));
conversions_id1.put(2,new SynergizerParams("ensembl", "entrezgene","uniprot_sptrembl"));
conversions_id1.put(3,new SynergizerParams("ncbi", "entrezgene","uniprot"));
//ncbi has no symbols so can only use ensembl
Expand All @@ -131,20 +131,20 @@ public void translate() throws IOException {
}else if(oldID.equalsIgnoreCase("uniprot")){
//for each conversion place in oldID to newID into hashmap
id1="entrezgene";
conversions_id1.put(1, new SynergizerParams("ensembl", "uniprot_swissprot_accession","entrezgene" ));
conversions_id1.put(1, new SynergizerParams("ensembl", "uniprot_swissprot","entrezgene" ));
conversions_id1.put(2,new SynergizerParams("ensembl", "uniprot_sptrembl","entrezgene" ));
conversions_id1.put(3, new SynergizerParams("ncbi", "uniprot","entrezgene" ));
//ncbi has no symbols so can only use ensembl
id2="symbol";
conversions_id2.put(1, new SynergizerParams("ensembl", "uniprot_swissprot_accession",symboldb ));
conversions_id2.put(1, new SynergizerParams("ensembl", "uniprot_swissprot",symboldb ));
conversions_id2.put(2, new SynergizerParams("ensembl", "uniprot_sptrembl",symboldb ));
}else if(oldID.equalsIgnoreCase("symbol")){
id1="entrezgene";
conversions_id1.put(1, new SynergizerParams("ensembl",symboldb, "entrezgene"));

id2="UniProt";
conversions_id2.put(1, new SynergizerParams("ensembl",symboldb,"uniprot_swissprot_accession"));
conversions_id2.put(2, new SynergizerParams("ensembl",symboldb,"uniprot_sptrembl_accession"));
conversions_id2.put(1, new SynergizerParams("ensembl",symboldb,"uniprot_swissprot"));
conversions_id2.put(2, new SynergizerParams("ensembl",symboldb,"uniprot_sptrembl"));
}
//Mouse go files use mgi ids, we need to convert the mgi to three different dbs , instead of the standard 2
else if(oldID.equalsIgnoreCase("mgi")){
Expand All @@ -158,8 +158,8 @@ else if(oldID.equalsIgnoreCase("mgi")){
//add an additional id.
String id3="UniProt";
HashMap<Integer, SynergizerParams> conversions_id3 = new HashMap<Integer,SynergizerParams>();
conversions_id3.put(1,new SynergizerParams("ensembl", "mgi_id", "uniprot_swissprot_accession") );
conversions_id3.put(2,new SynergizerParams("ensembl", "mgi_id", "uniprot_sptrembl_accession") );
conversions_id3.put(1,new SynergizerParams("ensembl", "mgi_id", "uniprot_swissprot") );
conversions_id3.put(2,new SynergizerParams("ensembl", "mgi_id", "uniprot_sptrembl") );
conversions_id3.put(3,new SynergizerParams("ncbi", "mgi", "uniprot"));
conversions.put(id3, conversions_id3);
createNewIdTracker(id3,unfoundIds,logs,translated_genesets );
Expand Down

0 comments on commit 41efea9

Please sign in to comment.