icn3d 3.31.7 → 3.31.9
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 +53 -25
- package/icn3d.min.js +3 -3
- package/icn3d.module.js +53 -25
- package/package.json +1 -1
package/icn3d.module.js
CHANGED
|
@@ -41834,6 +41834,7 @@ class AnnoIg {
|
|
|
41834
41834
|
ic.chain2igArray[chnid] = [];
|
|
41835
41835
|
this.setChain2igArray(chnid, giSeq, bCustom);
|
|
41836
41836
|
|
|
41837
|
+
|
|
41837
41838
|
// remove Igs without BCEF strands one more time
|
|
41838
41839
|
let igArray = ic.chain2igArray[chnid];
|
|
41839
41840
|
|
|
@@ -41906,6 +41907,7 @@ class AnnoIg {
|
|
|
41906
41907
|
}
|
|
41907
41908
|
}
|
|
41908
41909
|
|
|
41910
|
+
|
|
41909
41911
|
// reset ic.chain2igArray
|
|
41910
41912
|
ic.chain2igArray[chnid] = [];
|
|
41911
41913
|
this.setChain2igArray(chnid, giSeq, bCustom);
|
|
@@ -45323,7 +45325,8 @@ class AddTrack {
|
|
|
45323
45325
|
}
|
|
45324
45326
|
|
|
45325
45327
|
getExonHtml(exonIndex, colorGradient, from, to, genomeRange, chainid, simpTitle) { let ic = this.icn3d; ic.icn3dui;
|
|
45326
|
-
return '<div style="display:inline-block; color:white!important; width:' + Math.round(ic.seqAnnWidth *(to - from + 1) /(ic.maxAnnoLength + ic.nTotalGap)) + 'px;" class="icn3d-seqTitle icn3d-link icn3d-blue" domain="' + (exonIndex + 1) + '" from="' + from + '" to="' + to + '" setname="' + simpTitle + ', Exon ' + (exonIndex + 1) + '" title="Exon ' + (exonIndex + 1) + ': ' + genomeRange + ' genomic interval" anno="sequence" chain="' + chainid + '"><div style="height: 12px; border: 1px solid #000; background: linear-gradient(to right, ' + colorGradient + ');"></div></div>';
|
|
45328
|
+
// return '<div style="display:inline-block; color:white!important; width:' + Math.round(ic.seqAnnWidth *(to - from + 1) /(ic.maxAnnoLength + ic.nTotalGap)) + 'px;" class="icn3d-seqTitle icn3d-link icn3d-blue" domain="' + (exonIndex + 1) + '" from="' + from + '" to="' + to + '" setname="' + simpTitle + ', Exon ' + (exonIndex + 1) + '" title="Exon ' + (exonIndex + 1) + ': ' + genomeRange + ' genomic interval" anno="sequence" chain="' + chainid + '"><div style="height: 12px; border: 1px solid #000; background: linear-gradient(to right, ' + colorGradient + ');"></div></div>';
|
|
45329
|
+
return '<div style="display:inline-block; color:white!important; width:' + Math.round(ic.seqAnnWidth *(to - from + 1) /(ic.maxAnnoLength + ic.nTotalGap)) + 'px;" class="icn3d-seqTitle icn3d-link icn3d-blue" domain="' + (exonIndex + 1) + '" from="' + from + '" to="' + to + '" setname="' + simpTitle + ', ' + (exonIndex + 1) + '" title="Exon: ' + genomeRange + ' genomic interval" anno="sequence" chain="' + chainid + '"><div style="height: 12px; border: 1px solid #000; background: linear-gradient(to right, ' + colorGradient + ');"></div></div>';
|
|
45327
45330
|
}
|
|
45328
45331
|
|
|
45329
45332
|
getExonColor(start, end, pos) { let ic = this.icn3d; ic.icn3dui;
|
|
@@ -52530,7 +52533,7 @@ class ContactMap {
|
|
|
52530
52533
|
let color2 = rHex + gHex + bHex;
|
|
52531
52534
|
|
|
52532
52535
|
if(bLink) linkStr += ', ';
|
|
52533
|
-
linkStr += '{"source": "' + idStr + postA + '", "target": "' + idStr2 + postB + '", "v": 11, "c": "' + color2 + '"}\n';
|
|
52536
|
+
linkStr += '{"source": "' + idStr + postA + '", "target": "' + idStr2 + postB + '", "v": 11, "c": "' + color2 + '", "pae": ' + parseInt(distMatrix[i][j]) + '}\n';
|
|
52534
52537
|
bLink = true;
|
|
52535
52538
|
}
|
|
52536
52539
|
}
|
|
@@ -56149,10 +56152,12 @@ class BcifParser {
|
|
|
56149
56152
|
let conf_type_idArray = struct_conf.getColumn("conf_type_id");
|
|
56150
56153
|
|
|
56151
56154
|
let chain1Array = struct_conf.getColumn("beg_auth_asym_id");
|
|
56152
|
-
let resi1Array = struct_conf.getColumn("beg_label_seq_id");
|
|
56155
|
+
// let resi1Array = struct_conf.getColumn("beg_label_seq_id");
|
|
56156
|
+
let resi1Array = struct_conf.getColumn("beg_auth_seq_id");
|
|
56153
56157
|
|
|
56154
56158
|
let chain2Array = struct_conf.getColumn("end_auth_asym_id");
|
|
56155
|
-
let resi2Array = struct_conf.getColumn("end_label_seq_id");
|
|
56159
|
+
// let resi2Array = struct_conf.getColumn("end_label_seq_id");
|
|
56160
|
+
let resi2Array = struct_conf.getColumn("end_auth_seq_id");
|
|
56156
56161
|
|
|
56157
56162
|
// Iterate through every row in the struct_conf category table, where each row delineates an interatomic connection
|
|
56158
56163
|
let confSize = struct_conf.rowCount;
|
|
@@ -56197,10 +56202,12 @@ class BcifParser {
|
|
|
56197
56202
|
let struct_sheet_range = block.getCategory("_struct_sheet_range");
|
|
56198
56203
|
|
|
56199
56204
|
let chain1Array = struct_sheet_range.getColumn("beg_auth_asym_id");
|
|
56200
|
-
let resi1Array = struct_sheet_range.getColumn("beg_label_seq_id");
|
|
56205
|
+
// let resi1Array = struct_sheet_range.getColumn("beg_label_seq_id");
|
|
56206
|
+
let resi1Array = struct_sheet_range.getColumn("beg_auth_seq_id");
|
|
56201
56207
|
|
|
56202
56208
|
let chain2Array = struct_sheet_range.getColumn("end_auth_asym_id");
|
|
56203
|
-
let resi2Array = struct_sheet_range.getColumn("end_label_seq_id");
|
|
56209
|
+
// let resi2Array = struct_sheet_range.getColumn("end_label_seq_id");
|
|
56210
|
+
let resi2Array = struct_sheet_range.getColumn("end_auth_seq_id");
|
|
56204
56211
|
|
|
56205
56212
|
// Iterate through every row in the struct_sheet_range category table, where each row delineates an interatomic connection
|
|
56206
56213
|
let sheetSize = struct_sheet_range.rowCount;
|
|
@@ -59705,9 +59712,13 @@ class ParserUtils {
|
|
|
59705
59712
|
|
|
59706
59713
|
for(let i = 0, il = ic.realignResid[chainid_t].length; i < il && i < ic.realignResid[chainid_q].length; ++i) {
|
|
59707
59714
|
let resid_t = ic.realignResid[chainid_t][i].resid;
|
|
59715
|
+
if(!resid_t) continue;
|
|
59716
|
+
|
|
59708
59717
|
let pos_t = resid_t.lastIndexOf('_');
|
|
59709
59718
|
let resi_t = parseInt(resid_t.substr(pos_t + 1));
|
|
59710
59719
|
let resid_q = ic.realignResid[chainid_q][i].resid;
|
|
59720
|
+
if(!resid_q) continue;
|
|
59721
|
+
|
|
59711
59722
|
let pos_q = resid_q.lastIndexOf('_');
|
|
59712
59723
|
let resi_q = parseInt(resid_q.substr(pos_q + 1));
|
|
59713
59724
|
|
|
@@ -63720,10 +63731,12 @@ class LoadCIF {
|
|
|
63720
63731
|
let conf_type_idArray = struct_conf.getColumn("conf_type_id");
|
|
63721
63732
|
|
|
63722
63733
|
let chain1Array = struct_conf.getColumn("beg_auth_asym_id");
|
|
63723
|
-
let resi1Array = struct_conf.getColumn("beg_label_seq_id");
|
|
63734
|
+
// let resi1Array = struct_conf.getColumn("beg_label_seq_id");
|
|
63735
|
+
let resi1Array = struct_conf.getColumn("beg_auth_seq_id");
|
|
63724
63736
|
|
|
63725
63737
|
struct_conf.getColumn("end_auth_asym_id");
|
|
63726
|
-
let resi2Array = struct_conf.getColumn("end_label_seq_id");
|
|
63738
|
+
// let resi2Array = struct_conf.getColumn("end_label_seq_id");
|
|
63739
|
+
let resi2Array = struct_conf.getColumn("end_auth_seq_id");
|
|
63727
63740
|
|
|
63728
63741
|
// Iterate through every row in the struct_conf category table, where each row delineates an interatomic connection
|
|
63729
63742
|
let confSize = struct_conf.rowCount;
|
|
@@ -63762,10 +63775,12 @@ class LoadCIF {
|
|
|
63762
63775
|
let struct_sheet_range = block.getCategory("_struct_sheet_range");
|
|
63763
63776
|
|
|
63764
63777
|
let chain1Array = struct_sheet_range.getColumn("beg_auth_asym_id");
|
|
63765
|
-
let resi1Array = struct_sheet_range.getColumn("beg_label_seq_id");
|
|
63778
|
+
// let resi1Array = struct_sheet_range.getColumn("beg_label_seq_id");
|
|
63779
|
+
let resi1Array = struct_sheet_range.getColumn("beg_auth_seq_id");
|
|
63766
63780
|
|
|
63767
63781
|
struct_sheet_range.getColumn("end_auth_asym_id");
|
|
63768
|
-
let resi2Array = struct_sheet_range.getColumn("end_label_seq_id");
|
|
63782
|
+
// let resi2Array = struct_sheet_range.getColumn("end_label_seq_id");
|
|
63783
|
+
let resi2Array = struct_sheet_range.getColumn("end_auth_seq_id");
|
|
63769
63784
|
|
|
63770
63785
|
// Iterate through every row in the struct_sheet_range category table, where each row delineates an interatomic connection
|
|
63771
63786
|
let sheetSize = struct_sheet_range.rowCount;
|
|
@@ -63773,7 +63788,7 @@ class LoadCIF {
|
|
|
63773
63788
|
let startChain = chain1Array.getString(i);
|
|
63774
63789
|
let startResi = parseInt(resi1Array.getString(i));
|
|
63775
63790
|
let endResi = parseInt(resi2Array.getString(i));
|
|
63776
|
-
|
|
63791
|
+
|
|
63777
63792
|
for(let j = startResi; j <= endResi; ++j) {
|
|
63778
63793
|
let resid = structure + "_" + startChain + "_" + j;
|
|
63779
63794
|
sheetArray.push(resid);
|
|
@@ -71377,7 +71392,7 @@ class Dssp {
|
|
|
71377
71392
|
ic.ref2igtype['LaminAC_1ifrA_human'] = 'Lamin';
|
|
71378
71393
|
ic.ref2igtype['MHCIa_7phrH_human_C1'] = 'IgC1';
|
|
71379
71394
|
ic.ref2igtype['MPT63_1lmiA_bacteria'] = 'IgE';
|
|
71380
|
-
ic.ref2igtype['NaCaExchanger_2fwuA_dog_n2'] = '
|
|
71395
|
+
ic.ref2igtype['NaCaExchanger_2fwuA_dog_n2'] = 'IgFN3-like';
|
|
71381
71396
|
ic.ref2igtype['NaKATPaseTransporterBeta_2zxeB_spurdogshark'] = 'IgE';
|
|
71382
71397
|
ic.ref2igtype['ORF7a_1xakA_virus'] = 'ORF';
|
|
71383
71398
|
ic.ref2igtype['PD1_4zqkB_human_V'] = 'IgV';
|
|
@@ -71804,12 +71819,13 @@ class Dssp {
|
|
|
71804
71819
|
// if(!(bBstrand && bCstrand && bEstrand && bFstrand)) {
|
|
71805
71820
|
if(!me.bNode && !(bBstrand && bCstrand && bEstrand && bFstrand)) console.log("Some of the Ig strands B, C, E, F are missing in the domain " + domainid + "...");
|
|
71806
71821
|
if(!me.bNode && !(bBSheet && bCSheet && bESheet && bFSheet)) console.log("Some of the Ig strands B, C, E, F are not beta sheets...");
|
|
71807
|
-
|
|
71822
|
+
|
|
71808
71823
|
if(ic.domainid2refpdbname[domainid][0] == refpdbname) {
|
|
71809
71824
|
delete ic.domainid2refpdbname[domainid];
|
|
71810
71825
|
delete ic.domainid2score[domainid];
|
|
71811
71826
|
}
|
|
71812
|
-
continue;
|
|
71827
|
+
continue;
|
|
71828
|
+
}
|
|
71813
71829
|
// }
|
|
71814
71830
|
|
|
71815
71831
|
}
|
|
@@ -72103,14 +72119,16 @@ class Dssp {
|
|
|
72103
72119
|
let resiDistToC = (bCpstrand) ? parseInt(CpAtom.resi) - parseInt(CAtom.resi) : parseInt(DAtom.resi) - parseInt(CAtom.resi);
|
|
72104
72120
|
let resiDistToE = (bCpstrand) ? parseInt(EAtom.resi) - parseInt(CpAtom.resi) : parseInt(EAtom.resi) - parseInt(DAtom.resi);
|
|
72105
72121
|
|
|
72122
|
+
let adjust = 1;
|
|
72123
|
+
|
|
72106
72124
|
if(bCpstrand) {
|
|
72107
|
-
if(distToC > distToE || (distToC == distToE && resiDistToC > resiDistToE)) { // rename C' to D
|
|
72125
|
+
if(distToC > distToE + adjust || (distToC == distToE + adjust && resiDistToC > resiDistToE + adjust)) { // rename C' to D
|
|
72108
72126
|
CpToDResi.push(CpAtom.resi);
|
|
72109
72127
|
if(!me.bNode) console.log("Rename strand C' to D: distToC " + distToC + " distToE " + distToE + " resiDistToC " + resiDistToC + " resiDistToE " + resiDistToE);
|
|
72110
72128
|
}
|
|
72111
72129
|
}
|
|
72112
72130
|
else if(bDstrand) {
|
|
72113
|
-
if(distToC < distToE || (distToC == distToE && resiDistToC < resiDistToE)) { // rename D to C'
|
|
72131
|
+
if(distToC + adjust < distToE || (distToC + adjust == distToE && resiDistToC + adjust < resiDistToE)) { // rename D to C'
|
|
72114
72132
|
DToCpResi.push(DAtom.resi);
|
|
72115
72133
|
if(!me.bNode) console.log("Rename strand D to C': distToC " + distToC + " distToE " + distToE + " resiDistToC " + resiDistToC + " resiDistToE " + resiDistToE);
|
|
72116
72134
|
}
|
|
@@ -72130,7 +72148,8 @@ class Dssp {
|
|
|
72130
72148
|
|
|
72131
72149
|
seg.q_start;
|
|
72132
72150
|
let qStartInt = parseInt(seg.q_start);
|
|
72133
|
-
|
|
72151
|
+
let postfix = '';
|
|
72152
|
+
if(isNaN(seg.q_start)) postfix = seg.q_start.substr(seg.q_start.length - 1, 1);
|
|
72134
72153
|
|
|
72135
72154
|
// one item in "seq"
|
|
72136
72155
|
// q_start and q_end are numbers, but saved in string
|
|
@@ -72145,7 +72164,7 @@ class Dssp {
|
|
|
72145
72164
|
//let refnum = qStart;
|
|
72146
72165
|
let refnum = qStartInt;
|
|
72147
72166
|
|
|
72148
|
-
let refnumLabel = this.getLabelFromRefnum(refnum);
|
|
72167
|
+
let refnumLabel = this.getLabelFromRefnum(refnum, postfix);
|
|
72149
72168
|
currStrand = (refnumLabel) ? refnumLabel.replace(new RegExp(refnum,'g'), '') : undefined;
|
|
72150
72169
|
|
|
72151
72170
|
let currStrandFinal = currStrand;
|
|
@@ -72167,7 +72186,7 @@ class Dssp {
|
|
|
72167
72186
|
}
|
|
72168
72187
|
|
|
72169
72188
|
if(currStrand != currStrandFinal) {
|
|
72170
|
-
refnumLabel = this.getLabelFromRefnum(refnum, currStrandFinal);
|
|
72189
|
+
refnumLabel = this.getLabelFromRefnum(refnum, postfix, currStrandFinal);
|
|
72171
72190
|
}
|
|
72172
72191
|
|
|
72173
72192
|
let atom = ic.firstAtomObjCls.getFirstAtomObj(ic.residues[resid]);
|
|
@@ -72203,7 +72222,7 @@ class Dssp {
|
|
|
72203
72222
|
}
|
|
72204
72223
|
}
|
|
72205
72224
|
|
|
72206
|
-
getStrandFromRefnum(oriRefnum,
|
|
72225
|
+
getStrandFromRefnum(oriRefnum, finalStrand) { let ic = this.icn3d; ic.icn3dui;
|
|
72207
72226
|
let refnum = parseInt(oriRefnum);
|
|
72208
72227
|
|
|
72209
72228
|
//N-terminus = 0999-0001
|
|
@@ -72282,16 +72301,25 @@ class Dssp {
|
|
|
72282
72301
|
else if(refnum > 9900) strand = undefined;
|
|
72283
72302
|
else strand = " ";
|
|
72284
72303
|
|
|
72285
|
-
if(
|
|
72304
|
+
if(finalStrand) strand = finalStrand;
|
|
72286
72305
|
|
|
72287
72306
|
return strand
|
|
72288
72307
|
}
|
|
72289
72308
|
|
|
72290
|
-
getLabelFromRefnum(oriRefnum,
|
|
72291
|
-
let strand = this.getStrandFromRefnum(oriRefnum,
|
|
72309
|
+
getLabelFromRefnum(oriRefnum, postfix, finalStrand) { let ic = this.icn3d; ic.icn3dui;
|
|
72310
|
+
let strand = this.getStrandFromRefnum(oriRefnum, finalStrand);
|
|
72311
|
+
|
|
72312
|
+
// rename C' to D or D to C'
|
|
72313
|
+
let refnum = oriRefnum.toString();
|
|
72314
|
+
if(finalStrand == "C'" && refnum.substr(0, 1) == '6') { // previous D
|
|
72315
|
+
refnum = '4' + refnum.substr(1);
|
|
72316
|
+
}
|
|
72317
|
+
else if(finalStrand == "D" && refnum.substr(0, 1) == '4') { // previous C'
|
|
72318
|
+
refnum = '6' + refnum.substr(1);
|
|
72319
|
+
}
|
|
72292
72320
|
|
|
72293
72321
|
if(strand) {
|
|
72294
|
-
return strand +
|
|
72322
|
+
return strand + refnum + postfix;
|
|
72295
72323
|
}
|
|
72296
72324
|
else {
|
|
72297
72325
|
return undefined;
|
|
@@ -81210,7 +81238,7 @@ class iCn3DUI {
|
|
|
81210
81238
|
//even when multiple iCn3D viewers are shown together.
|
|
81211
81239
|
this.pre = this.cfg.divid + "_";
|
|
81212
81240
|
|
|
81213
|
-
this.REVISION = '3.31.
|
|
81241
|
+
this.REVISION = '3.31.2';
|
|
81214
81242
|
|
|
81215
81243
|
// In nodejs, iCn3D defines "window = {navigator: {}}"
|
|
81216
81244
|
this.bNode = (Object.keys(window).length < 2) ? true : false;
|