icn3d 3.26.9 → 3.27.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/icn3d.js +338 -174
- package/icn3d.min.js +3 -3
- package/icn3d.module.js +338 -174
- package/package.json +1 -1
package/icn3d.js
CHANGED
|
@@ -4456,23 +4456,23 @@ class ParasCls {
|
|
|
4456
4456
|
//this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * ( + 0.81)/(1.14 + 0.81)),
|
|
4457
4457
|
// hydrophobic
|
|
4458
4458
|
// https://en.m.wikipedia.org/wiki/Hydrophobicity_scales#Wimley%E2%80%93White_whole_residue_hydrophobicity_scales
|
|
4459
|
-
'TRP': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (-
|
|
4460
|
-
'PHE': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (-1.
|
|
4461
|
-
'
|
|
4462
|
-
'
|
|
4463
|
-
'
|
|
4464
|
-
'
|
|
4465
|
-
'
|
|
4459
|
+
'TRP': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (-2.09 + 2.09) / (0 + 2.09)),
|
|
4460
|
+
'PHE': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (-1.71 + 2.09) / (0 + 2.09)),
|
|
4461
|
+
'LEU': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (-1.25 + 2.09) / (0 + 2.09)),
|
|
4462
|
+
'ILE': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (-1.12 + 2.09) / (0 + 2.09)),
|
|
4463
|
+
'TYR': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (-0.71 + 2.09) / (0 + 2.09)),
|
|
4464
|
+
'MET': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (-0.67 + 2.09) / (0 + 2.09)),
|
|
4465
|
+
'VAL': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (-0.46 + 2.09) / (0 + 2.09)),
|
|
4466
|
+
'CYS': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (-0.02 + 2.09) / (0 + 2.09)),
|
|
4466
4467
|
|
|
4467
4468
|
// polar
|
|
4468
|
-
'
|
|
4469
|
-
'
|
|
4470
|
-
'SER': this.thr().setHSL(1/6.0, 1, 0.5 + 0.5 * (-0.
|
|
4471
|
-
'
|
|
4472
|
-
'
|
|
4473
|
-
'ASN': this.thr().setHSL(1/6.0, 1, 0.5 + 0.5 * (-0.
|
|
4474
|
-
'
|
|
4475
|
-
'GLN': this.thr().setHSL(1/6.0, 1, 0.5 + 0.5 * (-0.58 + 0.58)/(0 + 0.58))
|
|
4469
|
+
'PRO': this.thr().setHSL(1/6.0, 1, 0.5 + 0.5 * (-0.14 + 1.15) / (0 + 1.15)),
|
|
4470
|
+
'THR': this.thr().setHSL(1/6.0, 1, 0.5 + 0.5 * (-0.25 + 1.15) / (0 + 1.15)),
|
|
4471
|
+
'SER': this.thr().setHSL(1/6.0, 1, 0.5 + 0.5 * (-0.46 + 1.15) / (0 + 1.15)),
|
|
4472
|
+
'ALA': this.thr().setHSL(1/6.0, 1, 0.5 + 0.5 * (-0.50 + 1.15) / (0 + 1.15)),
|
|
4473
|
+
'GLN': this.thr().setHSL(1/6.0, 1, 0.5 + 0.5 * (-0.77 + 1.15) / (0 + 1.15)),
|
|
4474
|
+
'ASN': this.thr().setHSL(1/6.0, 1, 0.5 + 0.5 * (-0.85 + 1.15) / (0 + 1.15)),
|
|
4475
|
+
'GLY': this.thr().setHSL(1/6.0, 1, 0.5 + 0.5 * (-1.15 + 1.15) / (0 + 1.15))
|
|
4476
4476
|
};
|
|
4477
4477
|
|
|
4478
4478
|
this.normalizedHPColors = {
|
|
@@ -4490,59 +4490,58 @@ class ParasCls {
|
|
|
4490
4490
|
//this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * ( + 0.81)/(1.14 + 0.81)),
|
|
4491
4491
|
// hydrophobic
|
|
4492
4492
|
// https://en.m.wikipedia.org/wiki/Hydrophobicity_scales#Wimley%E2%80%93White_whole_residue_hydrophobicity_scales
|
|
4493
|
-
//
|
|
4494
|
-
'TRP': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (-
|
|
4495
|
-
'PHE': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (-1.
|
|
4496
|
-
'
|
|
4497
|
-
'
|
|
4498
|
-
'
|
|
4499
|
-
'
|
|
4500
|
-
'
|
|
4493
|
+
// 1.15 ~ -2.09: white ~ green
|
|
4494
|
+
'TRP': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (-2.09 + 2.09) / 3.24),
|
|
4495
|
+
'PHE': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (-1.71 + 2.09) / 3.24),
|
|
4496
|
+
'LEU': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (-1.25 + 2.09) / 3.24),
|
|
4497
|
+
'ILE': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (-1.12 + 2.09) / 3.24),
|
|
4498
|
+
'TYR': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (-0.71 + 2.09) / 3.24),
|
|
4499
|
+
'MET': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (-0.67 + 2.09) / 3.24),
|
|
4500
|
+
'VAL': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (-0.46 + 2.09) / 3.24),
|
|
4501
|
+
'CYS': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (-0.02 + 2.09) / 3.24),
|
|
4501
4502
|
|
|
4502
4503
|
// polar
|
|
4503
|
-
'
|
|
4504
|
-
'
|
|
4505
|
-
'SER': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (0.
|
|
4506
|
-
'
|
|
4507
|
-
'
|
|
4508
|
-
'ASN': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (0.
|
|
4509
|
-
'
|
|
4510
|
-
'GLN': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (0.58 + 1.85)/2.5)
|
|
4504
|
+
'PRO': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (0.14 + 2.09) / 3.24),
|
|
4505
|
+
'THR': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (0.25 + 2.09) / 3.24),
|
|
4506
|
+
'SER': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (0.46 + 2.09) / 3.24),
|
|
4507
|
+
'ALA': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (0.50 + 2.09) / 3.24),
|
|
4508
|
+
'GLN': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (0.77 + 2.09) / 3.24),
|
|
4509
|
+
'ASN': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (0.85 + 2.09) / 3.24),
|
|
4510
|
+
'GLY': this.thr().setHSL(1/3.0, 1, 0.5 + 0.5 * (1.15 + 2.09) / 3.24)
|
|
4511
4511
|
};
|
|
4512
4512
|
|
|
4513
4513
|
this.hydrophobicValues = {
|
|
4514
|
-
// charged residues
|
|
4514
|
+
// charged residues, larger than max polar (1.15)
|
|
4515
4515
|
' G': 3, ' A': 3, ' T': 3,
|
|
4516
4516
|
' C': 3, ' U': 3, ' DG': 3,
|
|
4517
4517
|
' DA': 3, ' DT': 3, ' DC': 3,
|
|
4518
4518
|
' DU': 3, 'G': 3, 'A': 3,
|
|
4519
4519
|
'T': 3, 'C': 3, 'U': 3,
|
|
4520
4520
|
'DG': 3, 'DA': 3, 'DT': 3,
|
|
4521
|
-
'DC': 3, 'DU': 3, 'ARG': 1,
|
|
4522
|
-
'LYS': 1, 'ASP': 3, 'GLU': 3,
|
|
4521
|
+
'DC': 3, 'DU': 3, 'ARG': 1.5,
|
|
4522
|
+
'LYS': 1.5, 'ASP': 3, 'GLU': 3,
|
|
4523
4523
|
'HIS': 2,
|
|
4524
4524
|
|
|
4525
|
-
// + 0.81)/(1.14 + 0.81)),
|
|
4526
4525
|
// hydrophobic
|
|
4527
4526
|
// https://en.m.wikipedia.org/wiki/Hydrophobicity_scales#Wimley%E2%80%93White_whole_residue_hydrophobicity_scales
|
|
4528
|
-
//
|
|
4529
|
-
'TRP': -
|
|
4530
|
-
'PHE': -1.
|
|
4531
|
-
'
|
|
4532
|
-
'
|
|
4533
|
-
'
|
|
4534
|
-
'
|
|
4535
|
-
'
|
|
4527
|
+
// 1.15 ~ -2.09: white ~ green
|
|
4528
|
+
'TRP': -2.09,
|
|
4529
|
+
'PHE': -1.71,
|
|
4530
|
+
'LEU': -1.25,
|
|
4531
|
+
'ILE': -1.12,
|
|
4532
|
+
'TYR': -0.71,
|
|
4533
|
+
'MET': -0.67,
|
|
4534
|
+
'VAL': -0.46,
|
|
4535
|
+
'CYS': -0.02,
|
|
4536
4536
|
|
|
4537
4537
|
// polar
|
|
4538
|
-
'
|
|
4539
|
-
'
|
|
4540
|
-
'SER': 0.
|
|
4541
|
-
'
|
|
4542
|
-
'
|
|
4543
|
-
'ASN': 0.
|
|
4544
|
-
'
|
|
4545
|
-
'GLN': 0.58
|
|
4538
|
+
'PRO': 0.14,
|
|
4539
|
+
'THR': 0.25,
|
|
4540
|
+
'SER': 0.46,
|
|
4541
|
+
'ALA': 0.50,
|
|
4542
|
+
'GLN': 0.77,
|
|
4543
|
+
'ASN': 0.85,
|
|
4544
|
+
'GLY': 1.15
|
|
4546
4545
|
};
|
|
4547
4546
|
|
|
4548
4547
|
this.residueAbbrev = {
|
|
@@ -5928,8 +5927,8 @@ class ClickMenu {
|
|
|
5928
5927
|
me.htmlCls.dialogCls.openDlg('dl_esmfold', 'Sequence to structure prediction with ESMFold');
|
|
5929
5928
|
});
|
|
5930
5929
|
|
|
5931
|
-
me.myEventCls.onIds("#" + me.pre + "
|
|
5932
|
-
me.htmlCls.dialogCls.openDlg('
|
|
5930
|
+
me.myEventCls.onIds("#" + me.pre + "mn1_proteinname", "click", function(e) { me.icn3d; //e.preventDefault();
|
|
5931
|
+
me.htmlCls.dialogCls.openDlg('dl_proteinname', 'Please input protein or gene name');
|
|
5933
5932
|
});
|
|
5934
5933
|
|
|
5935
5934
|
me.myEventCls.onIds("#" + me.pre + "mn1_cid", "click", function(e) { me.icn3d; //e.preventDefault();
|
|
@@ -8454,10 +8453,16 @@ class SetMenu {
|
|
|
8454
8453
|
let html = "";
|
|
8455
8454
|
|
|
8456
8455
|
html += "<ul class='icn3d-mn-item'>";
|
|
8457
|
-
|
|
8458
|
-
html += this.
|
|
8456
|
+
|
|
8457
|
+
html += this.getMenuText('mn1_searchgrooup', 'Search Structure ' + me.htmlCls.wifiStr, undefined, 1, 1);
|
|
8458
|
+
html += "<ul>";
|
|
8459
|
+
html += this.getMenuUrl('mn1_searchstru', 'https://www.ncbi.nlm.nih.gov/structure', 'PDB Structures ' + me.htmlCls.wifiStr, undefined, 2);
|
|
8460
|
+
html += this.getLink('mn1_proteinname', 'AlphaFold Structures ' + me.htmlCls.wifiStr, undefined, 2);
|
|
8461
|
+
html += this.getMenuUrl('mn1_afdatabase', 'https://alphafold.ebi.ac.uk', 'AlphaFold UniProt Database ' + me.htmlCls.wifiStr, undefined, 2);
|
|
8462
|
+
html += "</ul>";
|
|
8463
|
+
html += "</li>";
|
|
8459
8464
|
|
|
8460
|
-
html += this.getMenuText('mn1_searchsimilar', 'Search Similar', undefined, undefined, 1);
|
|
8465
|
+
html += this.getMenuText('mn1_searchsimilar', 'Search Similar' + me.htmlCls.wifiStr, undefined, undefined, 1);
|
|
8461
8466
|
html += "<ul>";
|
|
8462
8467
|
html += this.getLink('mn1_vastplus', 'NCBI VAST+ (PDB Complex)' + me.htmlCls.wifiStr, undefined, 2);
|
|
8463
8468
|
html += this.getLink('mn1_vast', 'NCBI VAST (PDB Chain)' + me.htmlCls.wifiStr, undefined, 2);
|
|
@@ -8478,7 +8483,6 @@ class SetMenu {
|
|
|
8478
8483
|
|
|
8479
8484
|
html += this.getLink('mn1_afid', 'UniProt ID ' + me.htmlCls.wifiStr, undefined, 3);
|
|
8480
8485
|
html += this.getLink('mn1_refseqid', 'NCBI Protein Accession ' + me.htmlCls.wifiStr, undefined, 3);
|
|
8481
|
-
// html += this.getLink('mn1_proteinname', 'Protein Name ' + me.htmlCls.wifiStr, undefined, 3);
|
|
8482
8486
|
html += "</ul>";
|
|
8483
8487
|
|
|
8484
8488
|
|
|
@@ -8520,10 +8524,11 @@ class SetMenu {
|
|
|
8520
8524
|
html += "</ul>";
|
|
8521
8525
|
html += "</li>";
|
|
8522
8526
|
|
|
8523
|
-
html += this.getMenuText('mn1_fold', 'AlphaFold/ESM', undefined, undefined, 1);
|
|
8527
|
+
//html += this.getMenuText('mn1_fold', 'AlphaFold/ESM', undefined, undefined, 1);
|
|
8528
|
+
html += this.getMenuText('mn1_fold', 'Predict by Seq.', undefined, undefined, 1);
|
|
8524
8529
|
html += "<ul>";
|
|
8525
|
-
html += this.getLink('mn1_alphafold', 'AlphaFold2 via ColabFold', undefined, 2);
|
|
8526
8530
|
html += this.getLink('mn1_esmfold', 'ESMFold', undefined, 2);
|
|
8531
|
+
html += this.getLink('mn1_alphafold', 'AlphaFold2 via ColabFold', undefined, 2);
|
|
8527
8532
|
html += "</ul>";
|
|
8528
8533
|
|
|
8529
8534
|
|
|
@@ -10341,6 +10346,9 @@ class Dialog {
|
|
|
10341
10346
|
if(me.cfg.align) {
|
|
10342
10347
|
position ={ my: "left top", at: "left top+90", of: "#" + me.pre + "canvas", collision: "none" };
|
|
10343
10348
|
}
|
|
10349
|
+
else if(id === me.pre + 'dl_mmdbafid') {
|
|
10350
|
+
position ={ my: "left top", at: "left top+130", of: "#" + me.pre + "canvas", collision: "none" };
|
|
10351
|
+
}
|
|
10344
10352
|
else {
|
|
10345
10353
|
position ={ my: "left top", at: "left top+50", of: "#" + me.pre + "canvas", collision: "none" };
|
|
10346
10354
|
}
|
|
@@ -10874,7 +10882,7 @@ class SetDialog {
|
|
|
10874
10882
|
|
|
10875
10883
|
html += me.htmlCls.divStr + "dl_esmfold' style='max-width:600px;' class='" + dialogClass + "'>";
|
|
10876
10884
|
html += this.addNotebookTitle('dl_esmfold', 'Sequence to structure prediction with ESMFold');
|
|
10877
|
-
html += "The sequence to structure prediction is done via <a href='https://esmatlas.com/resources?action=fold' target='_blank'>ESM Metagenomic Atlas</a>.
|
|
10885
|
+
html += "The sequence to structure prediction is done via <a href='https://esmatlas.com/resources?action=fold' target='_blank'>ESM Metagenomic Atlas</a>. The sequence should be less than 400 characters. For any sequence longer than 400, please see the discussion <a href='https://github.com/facebookresearch/esm/issues/21' target='_blank'>here</a>.<br><br> ";
|
|
10878
10886
|
html += "FASTA sequence: <br><textarea id='" + me.pre + "esmfold_fasta' rows='5' style='width: 100%; height: " +(me.htmlCls.LOG_HEIGHT) + "px; padding: 0px; border: 0px;'></textarea><br><br>";
|
|
10879
10887
|
html += me.htmlCls.buttonStr + "run_esmfold'>ESMFold</button> ";
|
|
10880
10888
|
html += "</div>";
|
|
@@ -10886,10 +10894,10 @@ class SetDialog {
|
|
|
10886
10894
|
html += me.htmlCls.buttonStr + "applyyournote'>Save</button>";
|
|
10887
10895
|
html += "</div>";
|
|
10888
10896
|
|
|
10889
|
-
html += me.htmlCls.divStr + "
|
|
10890
|
-
html += this.addNotebookTitle('
|
|
10891
|
-
html += "Protein
|
|
10892
|
-
html += me.htmlCls.buttonStr + "
|
|
10897
|
+
html += me.htmlCls.divStr + "dl_proteinname' class='" + dialogClass + "'>";
|
|
10898
|
+
html += this.addNotebookTitle('dl_proteinname', 'Please input a protein/gene name');
|
|
10899
|
+
html += "Protein/Gene name: " + me.htmlCls.inputTextStr + "id='" + me.pre + "proteinname' value='TP53' size=8> ";
|
|
10900
|
+
html += me.htmlCls.buttonStr + "reload_proteinname'>Search</button>";
|
|
10893
10901
|
html += "</div>";
|
|
10894
10902
|
|
|
10895
10903
|
html += me.htmlCls.divStr + "dl_cid' class='" + dialogClass + "'>";
|
|
@@ -12879,12 +12887,19 @@ class Events {
|
|
|
12879
12887
|
}
|
|
12880
12888
|
|
|
12881
12889
|
let esmfold_fasta = $("#" + me.pre + "esmfold_fasta").val();
|
|
12882
|
-
let pdbid;
|
|
12890
|
+
let pdbid = 'stru--';
|
|
12883
12891
|
|
|
12884
12892
|
if(esmfold_fasta.indexOf('>') != -1) { //FASTA with header
|
|
12885
12893
|
let pos = esmfold_fasta.indexOf('\n');
|
|
12886
12894
|
ic.esmTitle = esmfold_fasta.substr(1, pos - 1).trim();
|
|
12887
|
-
|
|
12895
|
+
if(ic.esmTitle.indexOf('|') != -1) { // uniprot
|
|
12896
|
+
let idArray = ic.esmTitle.split('|');
|
|
12897
|
+
pdbid = (idArray.length > 2) ? idArray[1] : ic.esmTitle;
|
|
12898
|
+
}
|
|
12899
|
+
else { // NCBI
|
|
12900
|
+
pdbid = (ic.esmTitle.indexOf(' ') != -1) ? ic.esmTitle.substr(0, ic.esmTitle.indexOf(' ')) : ic.esmTitle;
|
|
12901
|
+
}
|
|
12902
|
+
|
|
12888
12903
|
if(pdbid.length < 6) pdbid = pdbid.padEnd(6, '-');
|
|
12889
12904
|
|
|
12890
12905
|
esmfold_fasta = esmfold_fasta.substr(pos + 1);
|
|
@@ -12893,8 +12908,8 @@ class Events {
|
|
|
12893
12908
|
// remove new lines
|
|
12894
12909
|
esmfold_fasta = esmfold_fasta.replace(/\s/g, '');
|
|
12895
12910
|
|
|
12896
|
-
if(esmfold_fasta.length >
|
|
12897
|
-
var aaa = 1; //alert("Your
|
|
12911
|
+
if(esmfold_fasta.length > 400) {
|
|
12912
|
+
var aaa = 1; //alert("Your sequence is larger than 400 characters. Please consider to split it as described at https://github.com/facebookresearch/esm/issues/21.");
|
|
12898
12913
|
return;
|
|
12899
12914
|
}
|
|
12900
12915
|
|
|
@@ -12903,6 +12918,11 @@ class Events {
|
|
|
12903
12918
|
thisClass.setLogCmd("Run ESMFold with the sequence " + esmfold_fasta, false);
|
|
12904
12919
|
|
|
12905
12920
|
let esmData = await me.getAjaxPostPromise(esmUrl, esmfold_fasta, true, alertMess, undefined, true, 'text');
|
|
12921
|
+
|
|
12922
|
+
ic.bInputfile = true;
|
|
12923
|
+
ic.InputfileType = 'pdb';
|
|
12924
|
+
ic.InputfileData = (ic.InputfileData) ? ic.InputfileData + '\nENDMDL\n' + esmData : esmData;
|
|
12925
|
+
|
|
12906
12926
|
ic.bEsmfold = true;
|
|
12907
12927
|
let bAppend = true;
|
|
12908
12928
|
await ic.pdbParserCls.loadPdbData(esmData, pdbid, undefined, bAppend, undefined, undefined, undefined, ic.bEsmfold);
|
|
@@ -12941,12 +12961,12 @@ class Events {
|
|
|
12941
12961
|
});
|
|
12942
12962
|
|
|
12943
12963
|
|
|
12944
|
-
me.myEventCls.onIds("#" + me.pre + "
|
|
12964
|
+
me.myEventCls.onIds("#" + me.pre + "reload_proteinname", "click", function(e) { let ic = me.icn3d;
|
|
12945
12965
|
e.preventDefault();
|
|
12946
12966
|
if(!me.cfg.notebook) dialog.dialog( "close" );
|
|
12947
|
-
thisClass.setLogCmd("load
|
|
12967
|
+
thisClass.setLogCmd("load protein " + $("#" + me.pre + "proteinname").val(), false);
|
|
12948
12968
|
let urlTarget = (ic.structures && Object.keys(ic.structures).length > 0) ? '_blank' : '_self';
|
|
12949
|
-
window.open(hostUrl + '?
|
|
12969
|
+
window.open(hostUrl + '?protein=' + $("#" + me.pre + "proteinname").val(), urlTarget);
|
|
12950
12970
|
});
|
|
12951
12971
|
|
|
12952
12972
|
me.myEventCls.onIds("#" + me.pre + "reload_refseq", "click", function(e) { let ic = me.icn3d;
|
|
@@ -14528,8 +14548,17 @@ class AlignSeq {
|
|
|
14528
14548
|
|
|
14529
14549
|
let chainHash = {};
|
|
14530
14550
|
if (alignChainArray !== undefined) {
|
|
14551
|
+
|
|
14531
14552
|
for (let i = 0, il = alignChainArray.length; i < il; ++i) {
|
|
14532
|
-
|
|
14553
|
+
let chainid = alignChainArray[i];
|
|
14554
|
+
|
|
14555
|
+
// make sure some residues are aligned
|
|
14556
|
+
if(ic.alnChainsSeq[chainid] && ic.alnChainsSeq[chainid].length > 0) {
|
|
14557
|
+
chainHash[chainid] = 1;
|
|
14558
|
+
}
|
|
14559
|
+
else {
|
|
14560
|
+
return { "sequencesHtml": sequencesHtml, "maxSeqCnt": maxSeqCnt };
|
|
14561
|
+
}
|
|
14533
14562
|
}
|
|
14534
14563
|
}
|
|
14535
14564
|
|
|
@@ -14544,7 +14573,7 @@ class AlignSeq {
|
|
|
14544
14573
|
let bHighlightChain;
|
|
14545
14574
|
let index = 0, prevResCnt2nd = 0;
|
|
14546
14575
|
let firstChainid, oriChainid;
|
|
14547
|
-
|
|
14576
|
+
console.log("alignChainArray.length: " + alignChainArray.length);
|
|
14548
14577
|
// for(let i in ic.alnChains) {
|
|
14549
14578
|
for (let m = 0, ml = alignChainArray.length; m < ml; ++m) {
|
|
14550
14579
|
let i = alignChainArray[m];
|
|
@@ -14721,7 +14750,7 @@ class AlignSeq {
|
|
|
14721
14750
|
//sequencesHtml += "<div class='icn3d-residueLine' style='white-space:nowrap;'><div class='icn3d-seqTitle' chain='" + i + "' anno='" + j + "'>" + annotitle + "</div>" + resiHtmlArray[j] + "<br/></div>";
|
|
14722
14751
|
sequencesHtml += "<div class='icn3d-residueLine' style='white-space:nowrap;'><div class='icn3d-seqTitle' anno='" + j + "'>" + annotitle + "</div>" + resiHtmlArray[j] + "<br/></div>";
|
|
14723
14752
|
}
|
|
14724
|
-
|
|
14753
|
+
|
|
14725
14754
|
sequencesHtml += '<div class="icn3d-seqTitle icn3d-link icn3d-blue" chain="' + i + '" anno="sequence" title="' + title + '">' + chainidTmp + ' </div><span class="icn3d-seqLine">' + seqHtml + '</span><br/>';
|
|
14726
14755
|
|
|
14727
14756
|
if (index > 0) prevResCnt2nd += seqLength;
|
|
@@ -35560,13 +35589,13 @@ class SetOption {
|
|
|
35560
35589
|
html += "<div>";
|
|
35561
35590
|
|
|
35562
35591
|
if(colorType == 'normalized hydrophobic') {
|
|
35563
|
-
html += "Dark green (W, F,
|
|
35564
|
-
html += "Light green (
|
|
35592
|
+
html += "Dark green (W, F, L, I, Y, M, V, C): Hydrophobic<br>";
|
|
35593
|
+
html += "Light green (P, T, S, A, Q, N, G): Polar<br>";
|
|
35565
35594
|
html += "Grey: Charged, not hydrophobic<br><br>";
|
|
35566
35595
|
}
|
|
35567
35596
|
else {
|
|
35568
|
-
html += "Green (W, F,
|
|
35569
|
-
html += "Yellow (
|
|
35597
|
+
html += "Green (W, F, L, I, Y, M, V, C): Hydrophobic<br>";
|
|
35598
|
+
html += "Yellow (P, T, S, A, Q, N, G): Polar<br>";
|
|
35570
35599
|
html += "Red: Negatively Charged<br>";
|
|
35571
35600
|
html += "Blue: Positively Charged<br><br>";
|
|
35572
35601
|
}
|
|
@@ -39125,7 +39154,7 @@ class Domain3d {
|
|
|
39125
39154
|
return {subdomains: subdomains, substruct: substruct, pos2resi: pos2resi };
|
|
39126
39155
|
} // end c2b_NewSplitChain
|
|
39127
39156
|
|
|
39128
|
-
getDomainJsonForAlign(atoms) { let ic = this.icn3d, me = ic.icn3dui;
|
|
39157
|
+
getDomainJsonForAlign(atoms, bForceOneDomain) { let ic = this.icn3d, me = ic.icn3dui;
|
|
39129
39158
|
let result = this.c2b_NewSplitChain(atoms);
|
|
39130
39159
|
|
|
39131
39160
|
let subdomains = result.subdomains;
|
|
@@ -39136,6 +39165,8 @@ class Domain3d {
|
|
|
39136
39165
|
let residueArray = Object.keys(residueHash);
|
|
39137
39166
|
let chnid = residueArray[0].substr(0, residueArray[0].lastIndexOf('_'));
|
|
39138
39167
|
|
|
39168
|
+
if(bForceOneDomain) subdomains = [];
|
|
39169
|
+
|
|
39139
39170
|
//the whole structure is also considered as a large domain
|
|
39140
39171
|
//if(subdomains.length == 0) {
|
|
39141
39172
|
//subdomains.push([parseInt(ic.chainsSeq[chnid][0].resi), parseInt(ic.chainsSeq[chnid][ic.chainsSeq[chnid].length - 1].resi)]);
|
|
@@ -40993,7 +41024,7 @@ class ShowAnno {
|
|
|
40993
41024
|
dataObj['targets'] = me.cfg.blast_rep_id + ':' + target_from_to_array.join(':');
|
|
40994
41025
|
}
|
|
40995
41026
|
|
|
40996
|
-
// get
|
|
41027
|
+
// get sequence
|
|
40997
41028
|
if(ic.blastAcxn) {
|
|
40998
41029
|
let chainid = me.cfg.afid + '_A';
|
|
40999
41030
|
let seq = '';
|
|
@@ -41024,7 +41055,7 @@ class ShowAnno {
|
|
|
41024
41055
|
idArray.push(me.cfg.query_id);
|
|
41025
41056
|
}
|
|
41026
41057
|
|
|
41027
|
-
// get
|
|
41058
|
+
// get sequence
|
|
41028
41059
|
if(ic.blastAcxn) {
|
|
41029
41060
|
let chainid = me.cfg.afid + '_A';
|
|
41030
41061
|
let seq = '';
|
|
@@ -41351,7 +41382,7 @@ class ShowAnno {
|
|
|
41351
41382
|
let data = ic.seqStructAlignData;
|
|
41352
41383
|
if(data.data !== undefined) {
|
|
41353
41384
|
query = data.data[0].query;
|
|
41354
|
-
// if target is
|
|
41385
|
+
// if target is sequence, the key is not chnid
|
|
41355
41386
|
//target = data.data[0].targets[chnid];
|
|
41356
41387
|
let keys = Object.keys(data.data[0].targets);
|
|
41357
41388
|
target = data.data[0].targets[keys[0]];
|
|
@@ -41363,7 +41394,7 @@ class ShowAnno {
|
|
|
41363
41394
|
evalue = target.scores.e_value.toPrecision(2);
|
|
41364
41395
|
if(evalue > 1e-200) evalue = parseFloat(evalue).toExponential();
|
|
41365
41396
|
target.scores.bit_score;
|
|
41366
|
-
// if target is
|
|
41397
|
+
// if target is sequence, the key is not chnid
|
|
41367
41398
|
// targetSeq = data.targets[chnid].seqdata;
|
|
41368
41399
|
let keys = Object.keys(data.targets);
|
|
41369
41400
|
targetSeq = data.targets[keys[0]].seqdata;
|
|
@@ -42807,7 +42838,7 @@ class HlSeq {
|
|
|
42807
42838
|
//});
|
|
42808
42839
|
|
|
42809
42840
|
// remove possible text selection
|
|
42810
|
-
// the following code caused the scroll of
|
|
42841
|
+
// the following code caused the scroll of sequence window to the top, remove it for now
|
|
42811
42842
|
/*
|
|
42812
42843
|
if(window.getSelection) {
|
|
42813
42844
|
if(window.getSelection().empty) { // Chrome
|
|
@@ -44395,26 +44426,22 @@ class LineGraph {
|
|
|
44395
44426
|
|
|
44396
44427
|
let pdbAjaxArray = [];
|
|
44397
44428
|
for(let k = 0, kl = ic.refpdbArray.length; k < kl; ++k) {
|
|
44398
|
-
//let urlpdb = me.htmlCls.baseUrl + "
|
|
44399
|
-
let urlpdb = me.htmlCls.baseUrl + "mmcifparser/mmcifparser.cgi?
|
|
44429
|
+
//let urlpdb = me.htmlCls.baseUrl + "mmcifparser/mmcifparser.cgi?refpdbid=" + ic.refpdbArray[k];
|
|
44430
|
+
let urlpdb = me.htmlCls.baseUrl + "mmcifparser/mmcifparser.cgi?refjsonid=" + ic.refpdbArray[k];
|
|
44400
44431
|
|
|
44401
44432
|
let pdbAjax = me.getAjaxPromise(urlpdb, 'text');
|
|
44402
44433
|
|
|
44403
44434
|
pdbAjaxArray.push(pdbAjax);
|
|
44404
44435
|
}
|
|
44405
44436
|
|
|
44406
|
-
try {
|
|
44437
|
+
// try {
|
|
44407
44438
|
let allPromise = Promise.allSettled(pdbAjaxArray);
|
|
44408
44439
|
ic.pdbDataArray = await allPromise;
|
|
44409
44440
|
await thisClass.parseRefPdbData(ic.pdbDataArray);
|
|
44410
|
-
}
|
|
44411
|
-
catch(err) {
|
|
44412
|
-
if(!me.bNode) var aaa = 1; //alert("Error in retrieveing reference PDB data...");
|
|
44413
|
-
//var aaa = 1; //alert("Error in retrieveing reference PDB data...");
|
|
44414
|
-
return;
|
|
44415
|
-
}
|
|
44416
|
-
|
|
44417
44441
|
// }
|
|
44442
|
+
// catch(err) {
|
|
44443
|
+
// if(!me.bNode) var aaa = 1; //alert("Error in retrieveing reference PDB data...");
|
|
44444
|
+
// return;
|
|
44418
44445
|
// }
|
|
44419
44446
|
}
|
|
44420
44447
|
|
|
@@ -44426,7 +44453,8 @@ class LineGraph {
|
|
|
44426
44453
|
let ajaxArray = [];
|
|
44427
44454
|
let domainidpairArray = [];
|
|
44428
44455
|
|
|
44429
|
-
|
|
44456
|
+
me.htmlCls.baseUrl + "tmalign/tmalign.cgi";
|
|
44457
|
+
let urlalign = me.htmlCls.baseUrl + "vastdyn/vastdyn.cgi";
|
|
44430
44458
|
|
|
44431
44459
|
if(!ic.resid2domainid) ic.resid2domainid = {};
|
|
44432
44460
|
//ic.resid2domainid = {};
|
|
@@ -44506,6 +44534,9 @@ class LineGraph {
|
|
|
44506
44534
|
|
|
44507
44535
|
for(let k = 0, kl = domainAtomsArray.length; k < kl; ++k) {
|
|
44508
44536
|
let pdb_target = ic.saveFileCls.getAtomPDB(domainAtomsArray[k], undefined, undefined, undefined, undefined, struct);
|
|
44537
|
+
let bForceOneDomain = true;
|
|
44538
|
+
let jsonStr_t = ic.domain3dCls.getDomainJsonForAlign(domainAtomsArray[k], bForceOneDomain);
|
|
44539
|
+
|
|
44509
44540
|
// ig strand for any subset will have the same k, use the number of residue to separate them
|
|
44510
44541
|
let atomFirst = ic.firstAtomObjCls.getFirstAtomObj(domainAtomsArray[k]);
|
|
44511
44542
|
let atomLast = ic.firstAtomObjCls.getLastAtomObj(domainAtomsArray[k]);
|
|
@@ -44515,14 +44546,19 @@ class LineGraph {
|
|
|
44515
44546
|
ic.domainid2pdb[domainid] = pdb_target;
|
|
44516
44547
|
|
|
44517
44548
|
for(let index = 0, indexl = dataArray.length; index < indexl; ++index) {
|
|
44518
|
-
let struct2 = ic.defaultPdbId + index;
|
|
44519
|
-
//let pdb_query =
|
|
44520
|
-
let
|
|
44521
|
-
|
|
44522
|
-
|
|
44523
|
-
|
|
44524
|
-
|
|
44525
|
-
let
|
|
44549
|
+
// let struct2 = ic.defaultPdbId + index;
|
|
44550
|
+
// let pdb_query = dataArray[index].value; //[0];
|
|
44551
|
+
// let header = 'HEADER ' + struct2 + '\n';
|
|
44552
|
+
// pdb_query = header + pdb_query;
|
|
44553
|
+
let jsonStr_q = dataArray[index].value; //[0];
|
|
44554
|
+
|
|
44555
|
+
// TM-align is not good when you align a full structure with the strand-only structure. VAST is better in this case.
|
|
44556
|
+
// let dataObj = {'pdb_query': pdb_query, 'pdb_target': pdb_target, "queryid": ic.refpdbArray[index]};
|
|
44557
|
+
// let alignAjax = me.getAjaxPostPromise(urltmalign, dataObj);
|
|
44558
|
+
|
|
44559
|
+
let dataObj = {'domains1': jsonStr_q, 'domains2': jsonStr_t};
|
|
44560
|
+
let alignAjax = me.getAjaxPostPromise(urlalign, dataObj);
|
|
44561
|
+
|
|
44526
44562
|
ajaxArray.push(alignAjax);
|
|
44527
44563
|
|
|
44528
44564
|
domainidpairArray.push(domainid + "|" + ic.refpdbArray[index]);
|
|
@@ -44601,6 +44637,7 @@ class LineGraph {
|
|
|
44601
44637
|
let thisClass = this;
|
|
44602
44638
|
|
|
44603
44639
|
let tmscoreThreshold = 0.4; // 0.4; //0.5;
|
|
44640
|
+
let rmsdThreshold = 10;
|
|
44604
44641
|
|
|
44605
44642
|
// find the best alignment for each chain
|
|
44606
44643
|
let domainid2score = {}, domainid2segs = {}, chainid2segs = {};
|
|
@@ -44628,8 +44665,15 @@ class LineGraph {
|
|
|
44628
44665
|
|
|
44629
44666
|
if(queryData.length == 0) continue;
|
|
44630
44667
|
|
|
44631
|
-
if(
|
|
44632
|
-
|
|
44668
|
+
if(!bRound1) {
|
|
44669
|
+
if(queryData[0].score < tmscoreThreshold || queryData[0].num_res < minResidues) {
|
|
44670
|
+
continue;
|
|
44671
|
+
}
|
|
44672
|
+
}
|
|
44673
|
+
else {
|
|
44674
|
+
if(queryData[0].super_rmsd > rmsdThreshold || queryData[0].num_res < minResidues) {
|
|
44675
|
+
continue;
|
|
44676
|
+
}
|
|
44633
44677
|
}
|
|
44634
44678
|
|
|
44635
44679
|
//let domainid_index = domainidpairArray[i].split(',');
|
|
@@ -44638,44 +44682,63 @@ class LineGraph {
|
|
|
44638
44682
|
let refpdbname = domainidpairArray[i].substr(domainidpairArray[i].indexOf('|') + 1);
|
|
44639
44683
|
//let chainid = domainid.split('-')[0];
|
|
44640
44684
|
|
|
44641
|
-
if(!
|
|
44685
|
+
if(!bRound1) {
|
|
44686
|
+
if(!me.bNode) console.log("refpdbname " + refpdbname + " TM-score: " + queryData[0].score);
|
|
44687
|
+
}
|
|
44688
|
+
else {
|
|
44689
|
+
if(!me.bNode) console.log("refpdbname " + refpdbname + " RMSD: " + queryData[0].super_rmsd);
|
|
44690
|
+
}
|
|
44642
44691
|
|
|
44643
44692
|
// Ig-like domains: B (2150, 2150a, 2150b), C (3150, 3250), E (7150, 7250), F (8150, 8250) strands
|
|
44644
44693
|
// Ig domain may require G (7050). But we'll leave that out for now.
|
|
44645
|
-
|
|
44646
|
-
|
|
44647
|
-
let
|
|
44694
|
+
if(!bRound1) {
|
|
44695
|
+
let bBstrand = false, bCstrand = false, bEstrand = false, bFstrand = false;
|
|
44696
|
+
for(let i = 0, il = queryData[0].segs.length; i < il; ++i) {
|
|
44697
|
+
let seg = queryData[0].segs[i];
|
|
44648
44698
|
|
|
44649
|
-
|
|
44650
|
-
|
|
44651
|
-
|
|
44652
|
-
|
|
44653
|
-
|
|
44654
|
-
|
|
44655
|
-
|
|
44656
|
-
|
|
44657
|
-
|
|
44658
|
-
|
|
44659
|
-
|
|
44699
|
+
if(seg.q_start.indexOf('2150') != -1 || seg.q_start.indexOf('2250') != -1) {
|
|
44700
|
+
bBstrand = true;
|
|
44701
|
+
}
|
|
44702
|
+
else if(seg.q_start.indexOf('3150') != -1 || seg.q_start.indexOf('3250') != -1) {
|
|
44703
|
+
bCstrand = true;
|
|
44704
|
+
}
|
|
44705
|
+
else if(seg.q_start.indexOf('7150') != -1 || seg.q_start.indexOf('7250') != -1) {
|
|
44706
|
+
bEstrand = true;
|
|
44707
|
+
}
|
|
44708
|
+
else if(seg.q_start.indexOf('8150') != -1 || seg.q_start.indexOf('8250') != -1) {
|
|
44709
|
+
bFstrand = true;
|
|
44710
|
+
}
|
|
44711
|
+
|
|
44712
|
+
//if(bBstrand && bCstrand && bEstrand && bFstrand && bGstrand) break;
|
|
44713
|
+
if(bBstrand && bCstrand && bEstrand && bFstrand) break;
|
|
44660
44714
|
}
|
|
44661
44715
|
|
|
44662
|
-
//if(bBstrand && bCstrand && bEstrand && bFstrand && bGstrand)
|
|
44663
|
-
if(bBstrand && bCstrand && bEstrand && bFstrand)
|
|
44716
|
+
//if(!(bBstrand && bCstrand && bEstrand && bFstrand && bGstrand)) continue;
|
|
44717
|
+
if(!(bBstrand && bCstrand && bEstrand && bFstrand)) {
|
|
44718
|
+
if(!me.bNode) console.log("Some of the Ig strands B, C, E, F are missing in the domain " + domainid + "...");
|
|
44719
|
+
continue;
|
|
44720
|
+
}
|
|
44664
44721
|
}
|
|
44665
44722
|
|
|
44666
|
-
|
|
44667
|
-
|
|
44668
|
-
|
|
44669
|
-
|
|
44723
|
+
if(!bRound1) {
|
|
44724
|
+
if(!domainid2score.hasOwnProperty(domainid) || queryData[0].score > domainid2score[domainid]) {
|
|
44725
|
+
domainid2score[domainid] = queryData[0].score;
|
|
44726
|
+
|
|
44727
|
+
ic.domainid2refpdbname[domainid] = refpdbname;
|
|
44728
|
+
domainid2segs[domainid] = queryData[0].segs;
|
|
44729
|
+
ic.domainid2ig2kabat[domainid] = queryData[0].ig2kabat;
|
|
44730
|
+
ic.domainid2ig2imgt[domainid] = queryData[0].ig2imgt;
|
|
44731
|
+
}
|
|
44670
44732
|
}
|
|
44671
|
-
|
|
44672
|
-
|
|
44673
|
-
|
|
44674
|
-
|
|
44675
|
-
|
|
44676
|
-
|
|
44677
|
-
|
|
44678
|
-
|
|
44733
|
+
else {
|
|
44734
|
+
if(!domainid2score.hasOwnProperty(domainid) || queryData[0].super_rmsd < domainid2score[domainid]) {
|
|
44735
|
+
domainid2score[domainid] = queryData[0].super_rmsd;
|
|
44736
|
+
|
|
44737
|
+
ic.domainid2refpdbname[domainid] = refpdbname;
|
|
44738
|
+
domainid2segs[domainid] = queryData[0].segs;
|
|
44739
|
+
ic.domainid2ig2kabat[domainid] = queryData[0].ig2kabat;
|
|
44740
|
+
ic.domainid2ig2imgt[domainid] = queryData[0].ig2imgt;
|
|
44741
|
+
}
|
|
44679
44742
|
}
|
|
44680
44743
|
}
|
|
44681
44744
|
|
|
@@ -48092,7 +48155,7 @@ class ChainalignParser {
|
|
|
48092
48155
|
let hAtomsAll = {};
|
|
48093
48156
|
|
|
48094
48157
|
if(ic.bFullUi && ic.q_rotation !== undefined && !me.cfg.resnum && !me.cfg.resdef) {
|
|
48095
|
-
// set multiple
|
|
48158
|
+
// set multiple sequence alignment from ic.qt_start_end
|
|
48096
48159
|
hAtomsAll = this.setMsa(chainidArray);
|
|
48097
48160
|
}
|
|
48098
48161
|
|
|
@@ -48152,7 +48215,7 @@ class ChainalignParser {
|
|
|
48152
48215
|
ic.qt_start_end = [];
|
|
48153
48216
|
|
|
48154
48217
|
let mmdbid2cnt = {}, mmdbidpairHash = {};
|
|
48155
|
-
|
|
48218
|
+
|
|
48156
48219
|
let bFoundAlignment = false;
|
|
48157
48220
|
for(let i = 0, il = dataArray.length; i < il; ++i) {
|
|
48158
48221
|
// let align = (me.bNode) ? dataArray[i] : dataArray[i].value;//[0];
|
|
@@ -48632,6 +48695,7 @@ class ChainalignParser {
|
|
|
48632
48695
|
|
|
48633
48696
|
processAlign(align, index, queryData, bEqualMmdbid, bEqualChain, bNoAlert) { let ic = this.icn3d, me = ic.icn3dui;
|
|
48634
48697
|
let bAligned = false;
|
|
48698
|
+
|
|
48635
48699
|
if((!align || align.length == 0) && !bNoAlert) {
|
|
48636
48700
|
let serverName = (me.cfg.aligntool == 'tmalign') ? 'TM-align' : 'VAST';
|
|
48637
48701
|
|
|
@@ -48816,14 +48880,14 @@ class ChainalignParser {
|
|
|
48816
48880
|
ic.ParserUtilsCls.showLoading();
|
|
48817
48881
|
|
|
48818
48882
|
let allPromise = Promise.allSettled(ajaxArray);
|
|
48819
|
-
try {
|
|
48883
|
+
// try {
|
|
48820
48884
|
let dataArray = await allPromise;
|
|
48821
48885
|
await thisClass.parseMMdbAfData(dataArray, structArray, bQuery, vastplusAtype);
|
|
48822
48886
|
if(vastplusAtype === undefined) ic.ParserUtilsCls.hideLoading();
|
|
48823
|
-
}
|
|
48824
|
-
catch(err) {
|
|
48825
|
-
|
|
48826
|
-
}
|
|
48887
|
+
// }
|
|
48888
|
+
// catch(err) {
|
|
48889
|
+
// var aaa = 1; //alert("There are some problems in retrieving the coordinates...");
|
|
48890
|
+
// }
|
|
48827
48891
|
// });
|
|
48828
48892
|
|
|
48829
48893
|
// return ic.deferredMmdbaf.promise();
|
|
@@ -49462,6 +49526,73 @@ class MmdbParser {
|
|
|
49462
49526
|
//await ic.loadScriptCls.loadScript(me.cfg.command, undefined, true);
|
|
49463
49527
|
}
|
|
49464
49528
|
|
|
49529
|
+
async downloadProteinname(protein) { let ic = this.icn3d, me = ic.icn3dui;
|
|
49530
|
+
me.icn3d.bCid = undefined;
|
|
49531
|
+
|
|
49532
|
+
// get RefSeq ID from protein name
|
|
49533
|
+
let url = me.htmlCls.baseUrl + "vastdyn/vastdyn.cgi?protein2acc=" + protein;
|
|
49534
|
+
|
|
49535
|
+
let accJson = await me.getAjaxPromise(url, 'jsonp');
|
|
49536
|
+
|
|
49537
|
+
let accArray = accJson.acc;
|
|
49538
|
+
|
|
49539
|
+
if(accArray.length == 0) {
|
|
49540
|
+
if(!me.bNode) var aaa = 1; //alert('The protein/gene name ' + protein + ' can not be mapped to RefSeq proteins...');
|
|
49541
|
+
return;
|
|
49542
|
+
}
|
|
49543
|
+
|
|
49544
|
+
let ajaxArray = [];
|
|
49545
|
+
for(let index = 0, indexl = accArray.length; index < indexl; ++index) {
|
|
49546
|
+
let refseqid = accArray[index];
|
|
49547
|
+
url = me.htmlCls.baseUrl + "vastdyn/vastdyn.cgi?refseq2uniprot=" + refseqid;
|
|
49548
|
+
|
|
49549
|
+
let ajax = me.getAjaxPromise(url, 'jsonp');
|
|
49550
|
+
|
|
49551
|
+
ajaxArray.push(ajax);
|
|
49552
|
+
}
|
|
49553
|
+
|
|
49554
|
+
let allPromise = Promise.allSettled(ajaxArray);
|
|
49555
|
+
let dataArray = await allPromise;
|
|
49556
|
+
|
|
49557
|
+
ajaxArray = [];
|
|
49558
|
+
let afidArray = [];
|
|
49559
|
+
for(let i = 0, il = dataArray.length; i < il; ++i) {
|
|
49560
|
+
let data = dataArray[i].value;
|
|
49561
|
+
|
|
49562
|
+
if(data && data.uniprot) {
|
|
49563
|
+
let afid = data.uniprot;
|
|
49564
|
+
url = "https://alphafold.ebi.ac.uk/files/AF-" + afid + "-F1-model_" + ic.AFUniprotVersion + ".pdb";
|
|
49565
|
+
ic.ParserUtilsCls.setYourNote(me.cfg.protein + '(NCBI Protein/Gene) in iCn3D');
|
|
49566
|
+
|
|
49567
|
+
let ajax = me.getAjaxPromise(url, 'text', true);
|
|
49568
|
+
ajaxArray.push(ajax);
|
|
49569
|
+
afidArray.push(afid);
|
|
49570
|
+
}
|
|
49571
|
+
}
|
|
49572
|
+
|
|
49573
|
+
allPromise = Promise.allSettled(ajaxArray);
|
|
49574
|
+
dataArray = await allPromise;
|
|
49575
|
+
|
|
49576
|
+
for(let i = 0, il = dataArray.length; i < il; ++i) {
|
|
49577
|
+
let data = dataArray[i].value;
|
|
49578
|
+
me.cfg.afid = afidArray[i];
|
|
49579
|
+
|
|
49580
|
+
if(data) {
|
|
49581
|
+
// add UniProt ID into the header
|
|
49582
|
+
let header = 'HEADER ' + me.cfg.afid + '\n';
|
|
49583
|
+
data = header + data;
|
|
49584
|
+
await ic.opmParserCls.parseAtomData(data, me.cfg.afid, undefined, 'pdb', undefined);
|
|
49585
|
+
|
|
49586
|
+
break;
|
|
49587
|
+
}
|
|
49588
|
+
}
|
|
49589
|
+
|
|
49590
|
+
if(!me.cfg.afid) {
|
|
49591
|
+
if(!me.bNode) var aaa = 1; //alert('The protein/gene name ' + protein + ' can not be mapped to AlphaFold structures...');
|
|
49592
|
+
return;
|
|
49593
|
+
}
|
|
49594
|
+
}
|
|
49595
|
+
|
|
49465
49596
|
getNoData(mmdbid, bGi) { let ic = this.icn3d, me = ic.icn3dui;
|
|
49466
49597
|
if(bGi) {
|
|
49467
49598
|
var aaa = 1; //alert("This gi " + mmdbid + " has no corresponding 3D structure...");
|
|
@@ -50538,6 +50669,9 @@ class PdbParser {
|
|
|
50538
50669
|
if(me.cfg.refseqid) {
|
|
50539
50670
|
ic.ParserUtilsCls.setYourNote(me.cfg.refseqid.toUpperCase() + '(NCBI Protein Acc.) in iCn3D');
|
|
50540
50671
|
}
|
|
50672
|
+
else if(me.cfg.protein) {
|
|
50673
|
+
ic.ParserUtilsCls.setYourNote(me.cfg.protein + '(NCBI Protein/Gene) in iCn3D');
|
|
50674
|
+
}
|
|
50541
50675
|
else {
|
|
50542
50676
|
ic.ParserUtilsCls.setYourNote(pdbid.toUpperCase() + '(AlphaFold) in iCn3D');
|
|
50543
50677
|
}
|
|
@@ -51473,6 +51607,7 @@ class RealignParser {
|
|
|
51473
51607
|
async realignOnStructAlign(bReverse) { let ic = this.icn3d, me = ic.icn3dui;
|
|
51474
51608
|
// each 3D domain should have at least 3 secondary structures
|
|
51475
51609
|
let minSseCnt = (me.cfg.aligntool != 'tmalign') ? 3 : 0;
|
|
51610
|
+
|
|
51476
51611
|
let struct2domain = {};
|
|
51477
51612
|
for(let struct in ic.structures) {
|
|
51478
51613
|
struct2domain[struct] = {};
|
|
@@ -51483,7 +51618,7 @@ class RealignParser {
|
|
|
51483
51618
|
let sseCnt = 0;
|
|
51484
51619
|
for(let serial in atoms) {
|
|
51485
51620
|
if(ic.atoms[serial].ssbegin) ++sseCnt;
|
|
51486
|
-
if(sseCnt
|
|
51621
|
+
if(sseCnt > minSseCnt) {
|
|
51487
51622
|
struct2domain[struct][chainid] = atoms;
|
|
51488
51623
|
break;
|
|
51489
51624
|
}
|
|
@@ -51515,7 +51650,6 @@ class RealignParser {
|
|
|
51515
51650
|
let chainid2 = chainidArray2[j];
|
|
51516
51651
|
|
|
51517
51652
|
let alignAjax;
|
|
51518
|
-
|
|
51519
51653
|
if(me.cfg.aligntool != 'tmalign') {
|
|
51520
51654
|
let jsonStr_q = ic.domain3dCls.getDomainJsonForAlign(struct2domain[struct2][chainid2]);
|
|
51521
51655
|
|
|
@@ -51554,7 +51688,7 @@ class RealignParser {
|
|
|
51554
51688
|
|
|
51555
51689
|
async realignOnStructAlignMsa(nameArray) { let ic = this.icn3d, me = ic.icn3dui;
|
|
51556
51690
|
// each 3D domain should have at least 3 secondary structures
|
|
51557
|
-
let minSseCnt = 3;
|
|
51691
|
+
let minSseCnt = (me.cfg.aligntool != 'tmalign') ? 3 : 0;
|
|
51558
51692
|
let chainid2domain = {};
|
|
51559
51693
|
|
|
51560
51694
|
for(let i = 0, il = nameArray.length; i < il; ++i) {
|
|
@@ -51563,7 +51697,7 @@ class RealignParser {
|
|
|
51563
51697
|
let sseCnt = 0;
|
|
51564
51698
|
for(let serial in atoms) {
|
|
51565
51699
|
if(ic.atoms[serial].ssbegin) ++sseCnt;
|
|
51566
|
-
if(sseCnt
|
|
51700
|
+
if(sseCnt > minSseCnt) {
|
|
51567
51701
|
chainid2domain[chainid] = atoms;
|
|
51568
51702
|
break;
|
|
51569
51703
|
}
|
|
@@ -53684,7 +53818,7 @@ class ParserUtils {
|
|
|
53684
53818
|
if(ic.bAnnoShown) await ic.showAnnoCls.showAnnotations();
|
|
53685
53819
|
}
|
|
53686
53820
|
|
|
53687
|
-
// Realign by
|
|
53821
|
+
// Realign by sequence alignment with the residues in "segment", i.e., transmembrane helix
|
|
53688
53822
|
let segment = data.segment; // e.g., " 361- 379 ( 359- 384)", the first range is trnasmembrane range,
|
|
53689
53823
|
//the second range is the range of the helix
|
|
53690
53824
|
let range = segment.replace(/ /gi, '').split('(')[0]; //361-379
|
|
@@ -55498,7 +55632,7 @@ class SetSeqAlign {
|
|
|
55498
55632
|
|
|
55499
55633
|
//mmdbid1 = ic.mmdbid_t;
|
|
55500
55634
|
mmdbid1 = chainidArray[0].substr(0, pos1); //.toUpperCase();
|
|
55501
|
-
mmdbid2 = chainid.substr(0, pos2); //.toUpperCase();
|
|
55635
|
+
mmdbid2 = chainid.substr(0, pos2); //.toUpperCase()mergeTwoSeqForAll;
|
|
55502
55636
|
|
|
55503
55637
|
chain1 = chainidArray[0].substr(pos1 + 1);
|
|
55504
55638
|
chain2 = chainid.substr(pos2 + 1);
|
|
@@ -55893,7 +56027,7 @@ class LoadPDB {
|
|
|
55893
56027
|
getStructureId(id, moleculeNum, bMutation) { let ic = this.icn3d; ic.icn3dui;
|
|
55894
56028
|
let structure = id;
|
|
55895
56029
|
|
|
55896
|
-
if(id == ic.defaultPdbId || bMutation) { // bMutation: side chain prediction
|
|
56030
|
+
if(id == ic.defaultPdbId || bMutation || ic.structures.hasOwnProperty(id)) { // bMutation: side chain prediction
|
|
55897
56031
|
structure = (moleculeNum === 1) ? id : id + moleculeNum.toString();
|
|
55898
56032
|
}
|
|
55899
56033
|
|
|
@@ -55961,7 +56095,7 @@ class LoadPDB {
|
|
|
55961
56095
|
let prevMissingChain = '';
|
|
55962
56096
|
let CSerial, prevCSerial, OSerial, prevOSerial;
|
|
55963
56097
|
|
|
55964
|
-
let bHeader = false;
|
|
56098
|
+
let bHeader = false, bFirstAtom = true;
|
|
55965
56099
|
|
|
55966
56100
|
for (let i in lines) {
|
|
55967
56101
|
let line = lines[i];
|
|
@@ -56122,7 +56256,11 @@ class LoadPDB {
|
|
|
56122
56256
|
ic.pmid = line.substr(19).trim();
|
|
56123
56257
|
}
|
|
56124
56258
|
} else if (record === 'ATOM ' || record === 'HETATM') {
|
|
56125
|
-
|
|
56259
|
+
if(bFirstAtom) {
|
|
56260
|
+
structure = this.getStructureId(id, moleculeNum, bMutation);
|
|
56261
|
+
|
|
56262
|
+
bFirstAtom = false;
|
|
56263
|
+
}
|
|
56126
56264
|
|
|
56127
56265
|
let alt = line.substr(16, 1);
|
|
56128
56266
|
//if (alt !== " " && alt !== "A") continue;
|
|
@@ -57013,7 +57151,7 @@ class Vastplus {
|
|
|
57013
57151
|
|
|
57014
57152
|
// reinitialize the alignment
|
|
57015
57153
|
$("#" + ic.pre + "dl_sequence2").html('');
|
|
57016
|
-
|
|
57154
|
+
|
|
57017
57155
|
for(let j = 0, jl = nodeArray.length; j < jl; ++j) {
|
|
57018
57156
|
let node = parseInt(nodeArray[j]);
|
|
57019
57157
|
let segs = queryDataArray[node][0].segs;
|
|
@@ -57090,7 +57228,7 @@ class Vastplus {
|
|
|
57090
57228
|
for(let j = 0, jl = nodeArray.length; j < jl; ++j) {
|
|
57091
57229
|
chainpairStr += chainidpairArray[parseInt(nodeArray[j])] + '; ';
|
|
57092
57230
|
}
|
|
57093
|
-
console.log("Selected the alignment: " + chainpairStr);
|
|
57231
|
+
if(!me.bNode) console.log("Selected the alignment: " + chainpairStr);
|
|
57094
57232
|
|
|
57095
57233
|
break;
|
|
57096
57234
|
}
|
|
@@ -57099,7 +57237,7 @@ class Vastplus {
|
|
|
57099
57237
|
for(let j = 0, jl = nodeArray.length; j < jl; ++j) {
|
|
57100
57238
|
chainpairStr += chainidpairArray[parseInt(nodeArray[j])] + '; ';
|
|
57101
57239
|
}
|
|
57102
|
-
console.log("skipped the alignment: " + chainpairStr);
|
|
57240
|
+
if(!me.bNode) console.log("skipped the alignment: " + chainpairStr);
|
|
57103
57241
|
}
|
|
57104
57242
|
}
|
|
57105
57243
|
}
|
|
@@ -60484,6 +60622,10 @@ class LoadScript {
|
|
|
60484
60622
|
me.cfg.refseqid = id;
|
|
60485
60623
|
await ic.mmdbParserCls.downloadRefseq(id);
|
|
60486
60624
|
}
|
|
60625
|
+
else if(command.indexOf('load protein') !== -1) {
|
|
60626
|
+
me.cfg.protein = id;
|
|
60627
|
+
await ic.mmdbParserCls.downloadProteinname(id);
|
|
60628
|
+
}
|
|
60487
60629
|
else if(command.indexOf('load seq_struct_ids ') !== -1) {
|
|
60488
60630
|
ic.bSmithwm = false;
|
|
60489
60631
|
ic.bLocalSmithwm = false;
|
|
@@ -61579,6 +61721,8 @@ class Selection {
|
|
|
61579
61721
|
ic.graphStr = this.getGraphDataForDisplayed();
|
|
61580
61722
|
}
|
|
61581
61723
|
|
|
61724
|
+
ic.saveFileCls.showTitle();
|
|
61725
|
+
|
|
61582
61726
|
// don not redraw graphs after the selection changes
|
|
61583
61727
|
/*
|
|
61584
61728
|
if(ic.bGraph) ic.drawGraphCls.drawGraph(ic.graphStr, ic.pre + 'dl_graph');
|
|
@@ -66818,7 +66962,7 @@ class ResizeCanvas {
|
|
|
66818
66962
|
//let itemArray = ['dl_selectannotations', 'dl_alignment', 'dl_2ddgm', 'dl_definedsets', 'dl_graph',
|
|
66819
66963
|
// 'dl_linegraph', 'dl_scatterplot', 'dl_contactmap', 'dl_allinteraction', 'dl_copyurl',
|
|
66820
66964
|
// 'dl_symmetry', 'dl_symd', 'dl_rmsd', 'dl_legend', 'dl_disttable'];
|
|
66821
|
-
let itemArray = ['dl_2ddgm', 'dl_2dctn', 'dl_alignment', 'dl_sequence2', 'dl_definedsets', 'dl_setsmenu', 'dl_command', 'dl_setoperations', 'dl_vast', 'dl_foldseek', 'dl_mmtfid', 'dl_pdbid', 'dl_afid', 'dl_opmid', 'dl_pdbfile', 'dl_pdbfile_app', 'dl_rescolorfile', 'dl_customcolor', 'dl_align', 'dl_alignaf', 'dl_chainalign', 'dl_chainalign2', 'dl_chainalign3', 'dl_mutation', 'dl_mol2file', 'dl_sdffile', 'dl_xyzfile', 'dl_afmapfile', 'dl_urlfile', 'dl_mmciffile', 'dl_mmcifid', 'dl_mmdbid', 'dl_mmdbafid', 'dl_blast_rep_id', 'dl_yournote', '
|
|
66965
|
+
let itemArray = ['dl_2ddgm', 'dl_2dctn', 'dl_alignment', 'dl_sequence2', 'dl_definedsets', 'dl_setsmenu', 'dl_command', 'dl_setoperations', 'dl_vast', 'dl_foldseek', 'dl_mmtfid', 'dl_pdbid', 'dl_afid', 'dl_opmid', 'dl_pdbfile', 'dl_pdbfile_app', 'dl_rescolorfile', 'dl_customcolor', 'dl_align', 'dl_alignaf', 'dl_chainalign', 'dl_chainalign2', 'dl_chainalign3', 'dl_mutation', 'dl_mol2file', 'dl_sdffile', 'dl_xyzfile', 'dl_afmapfile', 'dl_urlfile', 'dl_mmciffile', 'dl_mmcifid', 'dl_mmdbid', 'dl_mmdbafid', 'dl_blast_rep_id', 'dl_yournote', 'dl_proteinname', 'dl_refseqid', 'dl_cid', 'dl_pngimage', 'dl_state', 'dl_fixedversion', 'dl_selection', 'dl_dsn6', 'dl_dsn6url', 'dl_clr', 'dl_symmetry', 'dl_symd', 'dl_contact', 'dl_hbonds', 'dl_realign', 'dl_realignbystruct', 'dl_allinteracton', 'dl_interactionsorted', 'dl_linegraph', 'dl_linegraphcolor', 'dl_scatterplot', 'dl_scatterploitcolor', 'dl_contactmap', 'dl_alignerrormap', 'dl_elecmap2fofc', 'dl_elecmapfofc', 'dl_emmap', 'dl_aroundsphere', 'dl_adjustmem', 'dl_selectplane', 'dl_addlabel', 'dl_addlabelselection', 'dl_labelColor', 'dl_distance', 'dl_stabilizer', 'dl_disttwosets', 'dl_distmanysets', 'dl_stabilizer_rm', 'dl_thickness', 'dl_thickness2', 'dl_addtrack', 'dl_addtrack_tabs', 'dl_saveselection', 'dl_copyurl', 'dl_selectannotations', 'dl_annotations_tabs', 'dl_anno_view_tabs', 'dl_annotations', 'dl_graph', 'dl_svgcolor', 'dl_area', 'dl_colorbyarea', 'dl_rmsd', 'dl_buriedarea', 'dl_propbypercentout', 'dl_propbybfactor', 'dl_legend', 'dl_disttable'];
|
|
66822
66966
|
|
|
66823
66967
|
for(let i in itemArray) {
|
|
66824
66968
|
let item = itemArray[i];
|
|
@@ -67952,13 +68096,13 @@ class SaveFile {
|
|
|
67952
68096
|
|
|
67953
68097
|
//Show the title and PDB ID of the PDB structure at the beginning of the viewer.
|
|
67954
68098
|
showTitle() {var ic = this.icn3d, me = ic.icn3dui;
|
|
67955
|
-
if(ic.molTitle !== undefined && ic.molTitle !== '') {
|
|
67956
|
-
let title = ic.molTitle;
|
|
68099
|
+
// if(ic.molTitle !== undefined && ic.molTitle !== '') {
|
|
68100
|
+
let title = (ic.molTitle) ? ic.molTitle : '';
|
|
67957
68101
|
|
|
67958
68102
|
let titlelinkColor =(ic.opts['background'] == 'black') ? me.htmlCls.GREYD : 'black';
|
|
67959
68103
|
|
|
67960
68104
|
if(ic.inputid === undefined) {
|
|
67961
|
-
if(
|
|
68105
|
+
if(title.length > 40) title = title.substr(0, 40) + "...";
|
|
67962
68106
|
|
|
67963
68107
|
$("#" + ic.pre + "title").html(title);
|
|
67964
68108
|
}
|
|
@@ -67978,31 +68122,38 @@ class SaveFile {
|
|
|
67978
68122
|
|
|
67979
68123
|
$("#" + ic.pre + "title").html(title);
|
|
67980
68124
|
}
|
|
67981
|
-
else if(me.cfg.mmdbafid !== undefined) {
|
|
67982
|
-
let structureArray = Object.keys(ic.structures); //me.cfg.mmdbafid.split(',');
|
|
68125
|
+
else { //if(me.cfg.mmdbafid !== undefined) {
|
|
68126
|
+
//let structureArray = Object.keys(ic.structures); //me.cfg.mmdbafid.split(',');
|
|
68127
|
+
let structureArray = Object.keys(me.utilsCls.getStructures(ic.dAtoms));
|
|
68128
|
+
|
|
67983
68129
|
if(structureArray.length > 1) {
|
|
67984
|
-
title = 'Multiple structures: '
|
|
68130
|
+
title = 'Multiple structures: ';
|
|
68131
|
+
for(let i = 0, il = structureArray.length; i < il; ++i) {
|
|
68132
|
+
let url = (isNaN(structureArray[i]) && structureArray[i].length > 5) ? 'https://alphafold.ebi.ac.uk/entry/' + structureArray[i] : 'https://www.ncbi.nlm.nih.gov/structure/?term=' + structureArray[i];
|
|
68133
|
+
title += '<a href="' + url + '" style="color:' + titlelinkColor + '" target="_blank">' + structureArray[i] + '</a>';
|
|
68134
|
+
if(i < il - 1) title += ', ';
|
|
68135
|
+
}
|
|
67985
68136
|
$("#" + ic.pre + "title").html(title);
|
|
67986
68137
|
}
|
|
67987
68138
|
else if(structureArray.length == 1) {
|
|
67988
68139
|
//let url = this.getLinkToStructureSummary();
|
|
67989
|
-
let url = (isNaN(
|
|
68140
|
+
let url = (isNaN(structureArray[0]) && structureArray[0].length > 5) ? 'https://alphafold.ebi.ac.uk/entry/' + structureArray[0] : 'https://www.ncbi.nlm.nih.gov/structure/?term=' + structureArray[0];
|
|
67990
68141
|
|
|
67991
68142
|
this.setStructureTitle(url, title, titlelinkColor);
|
|
67992
68143
|
}
|
|
67993
68144
|
}
|
|
67994
|
-
else {
|
|
67995
|
-
|
|
67996
|
-
|
|
67997
|
-
}
|
|
67998
|
-
}
|
|
67999
|
-
else {
|
|
68000
|
-
|
|
68001
|
-
}
|
|
68145
|
+
// else {
|
|
68146
|
+
// let url = this.getLinkToStructureSummary();
|
|
68147
|
+
// this.setStructureTitle(url, title, titlelinkColor);
|
|
68148
|
+
// }
|
|
68149
|
+
// }
|
|
68150
|
+
// else {
|
|
68151
|
+
// $("#" + ic.pre + "title").html("");
|
|
68152
|
+
// }
|
|
68002
68153
|
}
|
|
68003
68154
|
|
|
68004
68155
|
setStructureTitle(url, title, titlelinkColor) {var ic = this.icn3d, me = ic.icn3dui;
|
|
68005
|
-
if(
|
|
68156
|
+
if(title.length > 40) title = title.substr(0, 40) + "...";
|
|
68006
68157
|
|
|
68007
68158
|
let inputid = ic.inputid;
|
|
68008
68159
|
|
|
@@ -68028,7 +68179,7 @@ class SaveFile {
|
|
|
68028
68179
|
let structureidArray = Object.keys(idHash);
|
|
68029
68180
|
inputid = structureidArray.join(',');
|
|
68030
68181
|
|
|
68031
|
-
text = (me.cfg.refseqid) ? ic.inputid : inputid.toUpperCase();
|
|
68182
|
+
text = (me.cfg.refseqid || me.cfg.protein) ? ic.inputid : inputid.toUpperCase();
|
|
68032
68183
|
|
|
68033
68184
|
//idName = (isNaN(inputid) && inputid.length > 5) ? "AlphaFold ID" : "PDB ID";
|
|
68034
68185
|
if(bPdb && bAlphaFold) {
|
|
@@ -68054,7 +68205,12 @@ class SaveFile {
|
|
|
68054
68205
|
}
|
|
68055
68206
|
}
|
|
68056
68207
|
|
|
68057
|
-
if(me.cfg.refseqid)
|
|
68208
|
+
if(me.cfg.refseqid) {
|
|
68209
|
+
idName = 'NCBI Protein Acc.';
|
|
68210
|
+
}
|
|
68211
|
+
else if(me.cfg.protein) {
|
|
68212
|
+
idName = 'Protein/Gene Name';
|
|
68213
|
+
}
|
|
68058
68214
|
|
|
68059
68215
|
if(!inputid || inputid.substr(0, 4) == ic.defaultPdbId) {
|
|
68060
68216
|
$("#" + ic.pre + "title").html(title);
|
|
@@ -71326,7 +71482,7 @@ class iCn3DUI {
|
|
|
71326
71482
|
//even when multiple iCn3D viewers are shown together.
|
|
71327
71483
|
this.pre = this.cfg.divid + "_";
|
|
71328
71484
|
|
|
71329
|
-
this.REVISION = '3.
|
|
71485
|
+
this.REVISION = '3.27.0';
|
|
71330
71486
|
|
|
71331
71487
|
// In nodejs, iCn3D defines "window = {navigator: {}}"
|
|
71332
71488
|
this.bNode = (Object.keys(window).length < 2) ? true : false;
|
|
@@ -71619,6 +71775,14 @@ iCn3DUI.prototype.show3DStructure = async function(pdbStr) { let me = this;
|
|
|
71619
71775
|
me.htmlCls.clickMenuCls.setLogCmd(ic.loadCmd, true);
|
|
71620
71776
|
await ic.mmdbParserCls.downloadRefseq(me.cfg.refseqid);
|
|
71621
71777
|
}
|
|
71778
|
+
else if(me.cfg.protein !== undefined) {
|
|
71779
|
+
ic.inputid = me.cfg.protein;
|
|
71780
|
+
|
|
71781
|
+
// ic.bNCBI = true;
|
|
71782
|
+
ic.loadCmd = 'load protein ' + me.cfg.protein;
|
|
71783
|
+
me.htmlCls.clickMenuCls.setLogCmd(ic.loadCmd, true);
|
|
71784
|
+
await ic.mmdbParserCls.downloadProteinname(me.cfg.protein);
|
|
71785
|
+
}
|
|
71622
71786
|
else if(me.cfg.blast_rep_id !== undefined) {
|
|
71623
71787
|
// ic.bNCBI = true;
|
|
71624
71788
|
ic.inputid = me.cfg.query_id + ',' + me.cfg.blast_rep_id;
|
|
@@ -71626,7 +71790,7 @@ iCn3DUI.prototype.show3DStructure = async function(pdbStr) { let me = this;
|
|
|
71626
71790
|
me.cfg.oriQuery_id = me.cfg.query_id;
|
|
71627
71791
|
me.cfg.oriBlast_rep_id = me.cfg.blast_rep_id;
|
|
71628
71792
|
|
|
71629
|
-
// custom
|
|
71793
|
+
// custom sequence has query_id such as "Query_78989" in BLAST
|
|
71630
71794
|
if(me.cfg.query_id.substr(0,5) !== 'Query' && me.cfg.rid === undefined) {
|
|
71631
71795
|
// make it backward compatible for figure 2 in iCn3D paper: https://academic.oup.com/bioinformatics/article/36/1/131/5520951
|
|
71632
71796
|
if(me.cfg.from == 'icn3d' && me.cfg.blast_rep_id == '1TSR_A' && me.cfg.query_id == 'NP_001108451.1') {
|