Delta Capure-C

Michael Shapiro

2025-10-07

deltaCaptureC

Introduction

The purpose of this package is to detect meso-scale changes in chromatin conformation from 3C data. Typical 3C data might look like the following:

chr start end EScells_1
chr2 13505797 13506141 2
chr2 13506144 13506556 2
chr2 13654334 13655871 14
chr2 105656443 105656693 241
chr2 105656696 105659412 263
chr2 105659415 105660479 126
chr2 105662321 105663389 275
chr2 105663392 105663974 615
chr2 173656857 173657083 2
chr2 173694707 173695349 2
chr2 173698231 173698911 4

The segments shown are restriction enzyme digestion fragments. The counts show the numbers of experimentally captured interactions captured interactions between each of these fragments and the Paupar viewpoint. This viewpoint lies in the region 105661048 -105661864 and we see higher numbers of captures for digestion fragments near the viewpoint. Packages like r3Cseq attempt to determine p-values for the numbers of captures for each fragment. In order to do this, it estimates a ‘background’ level of interaction as a function of distance from the viewpoint. Comparing the count for each fragment to this background level allows it to estimate significance for each fragment.

This method makes only limited use of positional information. While it considers distance from the viewpoint in estimating background levels it ignores the proximity of individual fragments. But suppose we have ten consecutive fragments, each with counts only slightly above background. None may rise to statistical significance on its own, but their co-location may make the group highly significant. We will exploit this observation to look for statistically significant changes in counts between treatments or cell types.

Consider 3C data for the same viewpoint for two replicates each for two different cell types.

chr start end EScells_1 EScells_2 Neu_1 Neu_2
chr2 6226506 6226673 0 2 0 0
chr2 6235906 6237082 0 0 0 1
chr2 6270043 6270850 1 0 0 0
chr2 105656443 105656693 241 120 184 82
chr2 105656696 105659412 263 215 365 225
chr2 105659415 105660479 126 182 220 160
chr2 105662321 105663389 275 90 171 133
chr2 105663392 105663974 615 166 327 301
chr2 179455636 179455885 0 0 0 1
chr2 179473020 179473517 0 0 0 3
chr2 179473520 179473584 0 0 0 3

We wish to discover regions where there is a statisitcally significant change in the interaction levels between the two cell types.

Difference in mean normalized counts:

The first task is to normalize the values for each of the cell types. This will allow us to find the mean count for each of the digestion fragments in each of the cell types and consequently find the difference in the mean normalized counts for the two cell types. Normalizing depends on estimating a size factor for each replicate. Here we are relying on DESeq2::estimateSizeFactorsForMatrix(). For further details see the DESeq2 vignette or Love, M.I., Huber, W., Anders, S. Moderated estimation of fold change and dispersion for RNA-seq data with DESeq2 Genome Biology 15(12):550 (2014)

We have included a miniature version of the summarized experiment miniSE in order to demonstrate the process of extracting the delta mean normalized value miniDeltaSE.

{r}
library(deltaCaptureC)
miniDeltaSE = getDeltaSE(miniSE)

The actual deltaSE comes from a SummarizedExperiment representing the complete data set for these four replicates and is subsequently trimmed to a region on chromosome2 surrounding our region of interest. After binning to a bin size of 1kb it looks like this:

#> $data
#>          start       end width        delta       ctr
#> 1    105161001 105162000   900  -2.43699776 105161500
#> 2    105162001 105163000   900   3.57383506 105162500
#> 3    105163001 105164000   900   9.91840563 105163500
#> 4    105164001 105165000   900   1.02742901 105164500
#> 5    105165001 105166000   900   1.29687709 105165500
#> 6    105166001 105167000   900   4.36381639 105166500
#> 7    105167001 105168000   900   1.25764091 105167500
#> 8    105168001 105169000   900   5.89664430 105168500
#> 9    105169001 105170000   900   6.45325823 105169500
#> 10   105170001 105171000   900   1.59476554 105170500
#> 11   105171001 105172000   900   4.07956283 105171500
#> 12   105172001 105173000   900   2.40338834 105172500
#> 13   105173001 105174000   900  -0.10405596 105173500
#> 14   105174001 105175000   900   1.85935535 105174500
#> 15   105175001 105176000   900   5.81017157 105175500
#> 16   105176001 105177000   900  -0.98089535 105176500
#> 17   105177001 105178000   900   1.82254116 105177500
#> 18   105178001 105179000   900  -1.63380237 105178500
#> 19   105179001 105180000   900   0.57444353 105179500
#> 20   105180001 105181000   900   0.32280599 105180500
#> 21   105181001 105182000   900   1.52375581 105181500
#> 22   105182001 105183000   900   0.15174045 105182500
#> 23   105183001 105184000   900   5.05983720 105183500
#> 24   105184001 105185000   900   5.63902538 105184500
#> 25   105185001 105186000   900  -0.14286512 105185500
#> 26   105186001 105187000   900   2.60200300 105186500
#> 27   105187001 105188000   900  -0.12477195 105187500
#> 28   105188001 105189000   900  -0.30652590 105188500
#> 29   105189001 105190000   900   5.81675180 105189500
#> 30   105190001 105191000   900   1.82304477 105190500
#> 31   105191001 105192000   900   1.80092550 105191500
#> 32   105192001 105193000   900   0.82782150 105192500
#> 33   105193001 105194000   900  -0.76753630 105193500
#> 34   105194001 105195000   900   7.25783038 105194500
#> 35   105195001 105196000   900  -0.01570106 105195500
#> 36   105196001 105197000   900   1.65142818 105196500
#> 37   105197001 105198000   900   0.46891344 105197500
#> 38   105198001 105199000   900   1.60305120 105198500
#> 39   105199001 105200000   900   0.00000000 105199500
#> 40   105200001 105201000   900   0.58922813 105200500
#> 41   105201001 105202000   900   0.65252284 105201500
#> 42   105202001 105203000   900  -3.19818005 105202500
#> 43   105203001 105204000   900   1.44053240 105203500
#> 44   105204001 105205000   900  -0.37050731 105204500
#> 45   105205001 105206000   900  -4.19972956 105205500
#> 46   105206001 105207000   900  -0.39704857 105206500
#> 47   105207001 105208000   900  -1.18774890 105207500
#> 48   105208001 105209000   900   0.53254711 105208500
#> 49   105209001 105210000   900  -1.72730252 105209500
#> 50   105210001 105211000   900   0.64427158 105210500
#> 51   105211001 105212000   900   1.74924201 105211500
#> 52   105212001 105213000   900   0.40394364 105212500
#> 53   105213001 105214000   900   3.65413895 105213500
#> 54   105214001 105215000   900   3.33422703 105214500
#> 55   105215001 105216000   900   9.13466127 105215500
#> 56   105216001 105217000   900  10.71375854 105216500
#> 57   105217001 105218000   900   3.90014982 105217500
#> 58   105218001 105219000   900   4.78954939 105218500
#> 59   105219001 105220000   900  -0.41998836 105219500
#> 60   105220001 105221000   900   3.49247257 105220500
#> 61   105221001 105222000   900   1.29136168 105221500
#> 62   105222001 105223000   900   0.87667550 105222500
#> 63   105223001 105224000   900   5.89145749 105223500
#> 64   105224001 105225000   900   2.86743815 105224500
#> 65   105225001 105226000   900   0.61567988 105225500
#> 66   105226001 105227000   900   0.38410322 105226500
#> 67   105227001 105228000   900  -0.31488585 105227500
#> 68   105228001 105229000   900  -0.37311767 105228500
#> 69   105229001 105230000   900  -0.24105546 105229500
#> 70   105230001 105231000   900   1.17492295 105230500
#> 71   105231001 105232000   900  -7.68562167 105231500
#> 72   105232001 105233000   900  -4.22545600 105232500
#> 73   105233001 105234000   900  -1.50298666 105233500
#> 74   105234001 105235000   900   3.08646564 105234500
#> 75   105235001 105236000   900  -7.02855321 105235500
#> 76   105236001 105237000   900  -4.70484204 105236500
#> 77   105237001 105238000   900   3.38472703 105237500
#> 78   105238001 105239000   900   0.38516313 105238500
#> 79   105239001 105240000   900   3.04562199 105239500
#> 80   105240001 105241000   900   9.28213537 105240500
#> 81   105241001 105242000   900  -0.08549404 105241500
#> 82   105242001 105243000   900   0.02945048 105242500
#> 83   105243001 105244000   900   1.90675585 105243500
#> 84   105244001 105245000   900  -3.42749903 105244500
#> 85   105245001 105246000   900   9.01128240 105245500
#> 86   105246001 105247000   900   3.00736577 105246500
#> 87   105247001 105248000   900  -2.15340696 105247500
#> 88   105248001 105249000   900  -4.04325209 105248500
#> 89   105249001 105250000   900  -0.01725584 105249500
#> 90   105250001 105251000   900   0.00000000 105250500
#> 91   105251001 105252000   900   0.86801981 105251500
#> 92   105252001 105253000   900  -9.66345124 105252500
#> 93   105253001 105254000   900  -0.43837430 105253500
#> 94   105254001 105255000   900   1.10595177 105254500
#> 95   105255001 105256000   900   1.55586023 105255500
#> 96   105256001 105257000   900   1.92056537 105256500
#> 97   105257001 105258000   900  -0.03200697 105257500
#> 98   105258001 105259000   900  -0.52827008 105258500
#> 99   105259001 105260000   900  -0.52827008 105259500
#> 100  105260001 105261000   900  -0.18359177 105260500
#> 101  105261001 105262000   900   7.36847864 105261500
#> 102  105262001 105263000   900   5.96542868 105262500
#> 103  105263001 105264000   900  -1.75988999 105263500
#> 104  105264001 105265000   900  13.71636319 105264500
#> 105  105265001 105266000   900  -0.29676745 105265500
#> 106  105266001 105267000   900  -8.78514061 105266500
#> 107  105267001 105268000   900   8.45712862 105267500
#> 108  105268001 105269000   900  -0.97214550 105268500
#> 109  105269001 105270000   900  -0.67212721 105269500
#> 110  105270001 105271000   900  -1.67409588 105270500
#> 111  105271001 105272000   900  -3.50629030 105271500
#> 112  105272001 105273000   900   0.19443660 105272500
#> 113  105273001 105274000   900  -0.57125181 105273500
#> 114  105274001 105275000   900  -3.57819950 105274500
#> 115  105275001 105276000   900  -0.19316674 105275500
#> 116  105276001 105277000   900  -2.69653169 105276500
#> 117  105277001 105278000   900  -6.12666109 105277500
#> 118  105278001 105279000   900   0.00000000 105278500
#> 119  105279001 105280000   900   0.00000000 105279500
#> 120  105280001 105281000   900  -1.52197516 105280500
#> 121  105281001 105282000   900  -1.13640158 105281500
#> 122  105282001 105283000   900  -1.77676090 105282500
#> 123  105283001 105284000   900   0.67991286 105283500
#> 124  105284001 105285000   900  -4.80287436 105284500
#> 125  105285001 105286000   900   2.74367698 105285500
#> 126  105286001 105287000   900   5.62389117 105286500
#> 127  105287001 105288000   900  -4.35299909 105287500
#> 128  105288001 105289000   900  -3.51003876 105288500
#> 129  105289001 105290000   900   2.07219680 105289500
#> 130  105290001 105291000   900  -4.85950090 105290500
#> 131  105291001 105292000   900   9.27203578 105291500
#> 132  105292001 105293000   900  -1.66360431 105292500
#> 133  105293001 105294000   900   1.25885757 105293500
#> 134  105294001 105295000   900   1.59000575 105294500
#> 135  105295001 105296000   900  -4.17050706 105295500
#> 136  105296001 105297000   900  11.74088507 105296500
#> 137  105297001 105298000   900  -2.39892626 105297500
#> 138  105298001 105299000   900   0.43070429 105298500
#> 139  105299001 105300000   900   1.91033969 105299500
#> 140  105300001 105301000   900  -0.22516351 105300500
#> 141  105301001 105302000   900  -0.77916702 105301500
#> 142  105302001 105303000   900  -3.42310183 105302500
#> 143  105303001 105304000   900   2.18473323 105303500
#> 144  105304001 105305000   900  12.18132964 105304500
#> 145  105305001 105306000   900   5.62158874 105305500
#> 146  105306001 105307000   900  -0.01238106 105306500
#> 147  105307001 105308000   900   6.62605725 105307500
#> 148  105308001 105309000   900  -4.93545703 105308500
#> 149  105309001 105310000   900  -8.57274599 105309500
#> 150  105310001 105311000   900  -4.91028138 105310500
#> 151  105311001 105312000   900   0.87234052 105311500
#> 152  105312001 105313000   900  -1.11204387 105312500
#> 153  105313001 105314000   900  -0.23603225 105313500
#> 154  105314001 105315000   900   4.47258321 105314500
#> 155  105315001 105316000   900  -3.79242417 105315500
#> 156  105316001 105317000   900   1.14082791 105316500
#> 157  105317001 105318000   900   0.59045240 105317500
#> 158  105318001 105319000   900   3.34414429 105318500
#> 159  105319001 105320000   900   1.88625355 105319500
#> 160  105320001 105321000   900  -0.92418804 105320500
#> 161  105321001 105322000   900  -0.14311394 105321500
#> 162  105322001 105323000   900   3.49106168 105322500
#> 163  105323001 105324000   900  -0.58344161 105323500
#> 164  105324001 105325000   900  -1.38772779 105324500
#> 165  105325001 105326000   900   2.67556883 105325500
#> 166  105326001 105327000   900   8.79368702 105326500
#> 167  105327001 105328000   900   3.94867597 105327500
#> 168  105328001 105329000   900   0.72616173 105328500
#> 169  105329001 105330000   900   4.03709307 105329500
#> 170  105330001 105331000   900   5.12771616 105330500
#> 171  105331001 105332000   900  -1.31488136 105331500
#> 172  105332001 105333000   900   0.29208741 105332500
#> 173  105333001 105334000   900  -1.11209681 105333500
#> 174  105334001 105335000   900  -0.94694782 105334500
#> 175  105335001 105336000   900  -0.78143494 105335500
#> 176  105336001 105337000   900  -1.27014867 105336500
#> 177  105337001 105338000   900 -24.89980003 105337500
#> 178  105338001 105339000   900  -7.57270153 105338500
#> 179  105339001 105340000   900  -0.33898446 105339500
#> 180  105340001 105341000   900   0.35498987 105340500
#> 181  105341001 105342000   900   5.92209771 105341500
#> 182  105342001 105343000   900  -4.64263587 105342500
#> 183  105343001 105344000   900  -0.19101471 105343500
#> 184  105344001 105345000   900  -1.71171181 105344500
#> 185  105345001 105346000   900  -5.37225414 105345500
#> 186  105346001 105347000   900   0.54487106 105346500
#> 187  105347001 105348000   900   1.26837402 105347500
#> 188  105348001 105349000   900   0.02506268 105348500
#> 189  105349001 105350000   900   0.02506268 105349500
#> 190  105350001 105351000   900  -5.07606080 105350500
#> 191  105351001 105352000   900  -0.17664059 105351500
#> 192  105352001 105353000   900   2.36507368 105352500
#> 193  105353001 105354000   900  -0.17062785 105353500
#> 194  105354001 105355000   900   2.02347440 105354500
#> 195  105355001 105356000   900  -2.43357455 105355500
#> 196  105356001 105357000   900  -4.06954764 105356500
#> 197  105357001 105358000   900   4.06183539 105357500
#> 198  105358001 105359000   900   6.19177284 105358500
#> 199  105359001 105360000   900  -1.27135025 105359500
#> 200  105360001 105361000   900   5.58148340 105360500
#> 201  105361001 105362000   900   6.31674592 105361500
#> 202  105362001 105363000   900  -0.17921486 105362500
#> 203  105363001 105364000   900   0.91944627 105363500
#> 204  105364001 105365000   900   1.42287606 105364500
#> 205  105365001 105366000   900   6.32131443 105365500
#> 206  105366001 105367000   900   8.52610569 105366500
#> 207  105367001 105368000   900   1.30985750 105367500
#> 208  105368001 105369000   900   0.21581353 105368500
#> 209  105369001 105370000   900   6.16343880 105369500
#> 210  105370001 105371000   900   2.53157463 105370500
#> 211  105371001 105372000   900  -7.46210562 105371500
#> 212  105372001 105373000   900  -1.11739551 105372500
#> 213  105373001 105374000   900   4.71188074 105373500
#> 214  105374001 105375000   900   6.99384523 105374500
#> 215  105375001 105376000   900   3.77993798 105375500
#> 216  105376001 105377000   900  10.23627025 105376500
#> 217  105377001 105378000   900   5.46073626 105377500
#> 218  105378001 105379000   900   3.35041193 105378500
#> 219  105379001 105380000   900   9.62099817 105379500
#> 220  105380001 105381000   900  -5.19768142 105380500
#> 221  105381001 105382000   900  -3.12299016 105381500
#> 222  105382001 105383000   900  -2.72435313 105382500
#> 223  105383001 105384000   900   1.71426925 105383500
#> 224  105384001 105385000   900  -0.83313428 105384500
#> 225  105385001 105386000   900   6.31807396 105385500
#> 226  105386001 105387000   900 -10.80582707 105386500
#> 227  105387001 105388000   900   0.87534320 105387500
#> 228  105388001 105389000   900  -0.94615772 105388500
#> 229  105389001 105390000   900   2.25826029 105389500
#> 230  105390001 105391000   900   2.05835163 105390500
#> 231  105391001 105392000   900   0.70949277 105391500
#> 232  105392001 105393000   900   4.60207562 105392500
#> 233  105393001 105394000   900   7.62705601 105393500
#> 234  105394001 105395000   900   7.53043594 105394500
#> 235  105395001 105396000   900 -12.47294874 105395500
#> 236  105396001 105397000   900   5.54999689 105396500
#> 237  105397001 105398000   900  -4.94843436 105397500
#> 238  105398001 105399000   900   5.56540126 105398500
#> 239  105399001 105400000   900   5.89219790 105399500
#> 240  105400001 105401000   900   3.87053989 105400500
#> 241  105401001 105402000   900   1.27739141 105401500
#> 242  105402001 105403000   900  -9.10684004 105402500
#> 243  105403001 105404000   900   0.40048863 105403500
#> 244  105404001 105405000   900   5.63319552 105404500
#> 245  105405001 105406000   900   3.78038390 105405500
#> 246  105406001 105407000   900  -0.37984691 105406500
#> 247  105407001 105408000   900   0.41469913 105407500
#> 248  105408001 105409000   900   0.49819172 105408500
#> 249  105409001 105410000   900   0.46338475 105409500
#> 250  105410001 105411000   900   3.77561367 105410500
#> 251  105411001 105412000   900   0.31099854 105411500
#> 252  105412001 105413000   900  -1.33693967 105412500
#> 253  105413001 105414000   900 -17.30161885 105413500
#> 254  105414001 105415000   900  -1.43049558 105414500
#> 255  105415001 105416000   900  -1.60906044 105415500
#> 256  105416001 105417000   900   2.42735695 105416500
#> 257  105417001 105418000   900  -0.56056125 105417500
#> 258  105418001 105419000   900   7.81450534 105418500
#> 259  105419001 105420000   900   9.92889558 105419500
#> 260  105420001 105421000   900   6.98876622 105420500
#> 261  105421001 105422000   900   1.22285721 105421500
#> 262  105422001 105423000   900   1.24627546 105422500
#> 263  105423001 105424000   900   3.23566926 105423500
#> 264  105424001 105425000   900   1.29620217 105424500
#> 265  105425001 105426000   900   8.07757556 105425500
#> 266  105426001 105427000   900   7.22850144 105426500
#> 267  105427001 105428000   900  -0.27519041 105427500
#> 268  105428001 105429000   900   1.26588414 105428500
#> 269  105429001 105430000   900  -1.86479728 105429500
#> 270  105430001 105431000   900 -16.38026341 105430500
#> 271  105431001 105432000   900  -7.49952606 105431500
#> 272  105432001 105433000   900  -4.39600547 105432500
#> 273  105433001 105434000   900  11.04773728 105433500
#> 274  105434001 105435000   900  -1.11039459 105434500
#> 275  105435001 105436000   900  -2.58992672 105435500
#> 276  105436001 105437000   900  -0.60125858 105436500
#> 277  105437001 105438000   900  -0.65855266 105437500
#> 278  105438001 105439000   900   1.89591746 105438500
#> 279  105439001 105440000   900 -19.03425219 105439500
#> 280  105440001 105441000   900  -3.04056029 105440500
#> 281  105441001 105442000   900  -1.66415452 105441500
#> 282  105442001 105443000   900 -21.25598841 105442500
#> 283  105443001 105444000   900  -4.62011807 105443500
#> 284  105444001 105445000   900 -11.16686003 105444500
#> 285  105445001 105446000   900  -5.73927840 105445500
#> 286  105446001 105447000   900   9.34863636 105446500
#> 287  105447001 105448000   900  -1.40177037 105447500
#> 288  105448001 105449000   900 -11.52282633 105448500
#> 289  105449001 105450000   900  -7.19031446 105449500
#> 290  105450001 105451000   900   3.66064044 105450500
#> 291  105451001 105452000   900   4.96397064 105451500
#> 292  105452001 105453000   900   9.25549310 105452500
#> 293  105453001 105454000   900   0.35320307 105453500
#> 294  105454001 105455000   900  -9.37343619 105454500
#> 295  105455001 105456000   900   8.38362744 105455500
#> 296  105456001 105457000   900   6.49967889 105456500
#> 297  105457001 105458000   900 -19.60542145 105457500
#> 298  105458001 105459000   900   0.08342873 105458500
#> 299  105459001 105460000   900   0.08342873 105459500
#> 300  105460001 105461000   900   0.08342873 105460500
#> 301  105461001 105462000   900  -0.01905449 105461500
#> 302  105462001 105463000   900  -6.69931026 105462500
#> 303  105463001 105464000   900   9.93836536 105463500
#> 304  105464001 105465000   900   3.30578667 105464500
#> 305  105465001 105466000   900  15.94640023 105465500
#> 306  105466001 105467000   900   1.54249575 105466500
#> 307  105467001 105468000   900   4.23374718 105467500
#> 308  105468001 105469000   900   4.23374718 105468500
#> 309  105469001 105470000   900   3.37647852 105469500
#> 310  105470001 105471000   900 -15.11580554 105470500
#> 311  105471001 105472000   900   1.28390664 105471500
#> 312  105472001 105473000   900  -4.03554159 105472500
#> 313  105473001 105474000   900   7.35665580 105473500
#> 314  105474001 105475000   900   0.15910155 105474500
#> 315  105475001 105476000   900  -0.39302921 105475500
#> 316  105476001 105477000   900  10.86625629 105476500
#> 317  105477001 105478000   900  -3.24419513 105477500
#> 318  105478001 105479000   900   4.71367135 105478500
#> 319  105479001 105480000   900   7.08881781 105479500
#> 320  105480001 105481000   900  -2.18320986 105480500
#> 321  105481001 105482000   900   3.39994241 105481500
#> 322  105482001 105483000   900  -5.70630334 105482500
#> 323  105483001 105484000   900  -5.94769863 105483500
#> 324  105484001 105485000   900  -7.01889827 105484500
#> 325  105485001 105486000   900  -6.84215340 105485500
#> 326  105486001 105487000   900  -6.61632298 105486500
#> 327  105487001 105488000   900   1.33372186 105487500
#> 328  105488001 105489000   900  -1.70829174 105488500
#> 329  105489001 105490000   900   5.41118062 105489500
#> 330  105490001 105491000   900   3.82364268 105490500
#> 331  105491001 105492000   900  10.65615498 105491500
#> 332  105492001 105493000   900   8.45593643 105492500
#> 333  105493001 105494000   900  -5.65320271 105493500
#> 334  105494001 105495000   900   2.19246527 105494500
#> 335  105495001 105496000   900  -0.99129409 105495500
#> 336  105496001 105497000   900   8.87255026 105496500
#> 337  105497001 105498000   900   0.73411352 105497500
#> 338  105498001 105499000   900  -5.45752085 105498500
#> 339  105499001 105500000   900   0.52962088 105499500
#> 340  105500001 105501000   900 -10.00730769 105500500
#> 341  105501001 105502000   900   3.75699188 105501500
#> 342  105502001 105503000   900  -5.08651245 105502500
#> 343  105503001 105504000   900  -6.31176485 105503500
#> 344  105504001 105505000   900  -0.45074080 105504500
#> 345  105505001 105506000   900   3.41025561 105505500
#> 346  105506001 105507000   900  -4.60771485 105506500
#> 347  105507001 105508000   900   1.11104515 105507500
#> 348  105508001 105509000   900  16.51299702 105508500
#> 349  105509001 105510000   900  -4.29091467 105509500
#> 350  105510001 105511000   900   2.53499362 105510500
#> 351  105511001 105512000   900  -1.39160424 105511500
#> 352  105512001 105513000   900  -4.10899600 105512500
#> 353  105513001 105514000   900  -5.53888171 105513500
#> 354  105514001 105515000   900  -8.05083285 105514500
#> 355  105515001 105516000   900   6.53916311 105515500
#> 356  105516001 105517000   900  10.44588387 105516500
#> 357  105517001 105518000   900   0.08007560 105517500
#> 358  105518001 105519000   900   5.35070371 105518500
#> 359  105519001 105520000   900  36.30453607 105519500
#> 360  105520001 105521000   900  -2.86343493 105520500
#> 361  105521001 105522000   900  -8.59699682 105521500
#> 362  105522001 105523000   900  -8.75471985 105522500
#> 363  105523001 105524000   900  -7.82806780 105523500
#> 364  105524001 105525000   900  10.41321398 105524500
#> 365  105525001 105526000   900   0.39951578 105525500
#> 366  105526001 105527000   900   0.29864254 105526500
#> 367  105527001 105528000   900   4.09195241 105527500
#> 368  105528001 105529000   900   4.17877548 105528500
#> 369  105529001 105530000   900 -13.88788667 105529500
#> 370  105530001 105531000   900  -5.24160483 105530500
#> 371  105531001 105532000   900  11.65241043 105531500
#> 372  105532001 105533000   900 -38.07452045 105532500
#> 373  105533001 105534000   900   0.92546548 105533500
#> 374  105534001 105535000   900  -0.04187674 105534500
#> 375  105535001 105536000   900   4.93287496 105535500
#> 376  105536001 105537000   900  -3.31800700 105536500
#> 377  105537001 105538000   900   2.35329784 105537500
#> 378  105538001 105539000   900   5.49471428 105538500
#> 379  105539001 105540000   900  -0.49232464 105539500
#> 380  105540001 105541000   900   0.53294162 105540500
#> 381  105541001 105542000   900   0.30800703 105541500
#> 382  105542001 105543000   900  -0.19837376 105542500
#> 383  105543001 105544000   900  -6.94323702 105543500
#> 384  105544001 105545000   900  -5.97402938 105544500
#> 385  105545001 105546000   900   4.83885261 105545500
#> 386  105546001 105547000   900   3.84689204 105546500
#> 387  105547001 105548000   900  -5.43334048 105547500
#> 388  105548001 105549000   900  16.43736730 105548500
#> 389  105549001 105550000   900  -8.53753704 105549500
#> 390  105550001 105551000   900   6.48143440 105550500
#> 391  105551001 105552000   900  11.18119284 105551500
#> 392  105552001 105553000   900  26.23117694 105552500
#> 393  105553001 105554000   900  -2.96459260 105553500
#> 394  105554001 105555000   900  -5.35813049 105554500
#> 395  105555001 105556000   900   3.56055583 105555500
#> 396  105556001 105557000   900   4.94511348 105556500
#> 397  105557001 105558000   900  -0.52804757 105557500
#> 398  105558001 105559000   900   0.00000000 105558500
#> 399  105559001 105560000   900   0.00000000 105559500
#> 400  105560001 105561000   900   0.00000000 105560500
#> 401  105561001 105562000   900   0.00000000 105561500
#> 402  105562001 105563000   900   3.57251476 105562500
#> 403  105563001 105564000   900   4.03673984 105563500
#> 404  105564001 105565000   900  -5.27221024 105564500
#> 405  105565001 105566000   900  -3.10202045 105565500
#> 406  105566001 105567000   900  14.27423880 105566500
#> 407  105567001 105568000   900 -20.20162461 105567500
#> 408  105568001 105569000   900   1.44080612 105568500
#> 409  105569001 105570000   900   4.56898412 105569500
#> 410  105570001 105571000   900   3.50842485 105570500
#> 411  105571001 105572000   900  -2.05168532 105571500
#> 412  105572001 105573000   900  23.36379929 105572500
#> 413  105573001 105574000   900  10.99815210 105573500
#> 414  105574001 105575000   900   6.37532620 105574500
#> 415  105575001 105576000   900   4.38910422 105575500
#> 416  105576001 105577000   900   6.19715167 105576500
#> 417  105577001 105578000   900   4.97837286 105577500
#> 418  105578001 105579000   900   6.98758772 105578500
#> 419  105579001 105580000   900  -0.94614696 105579500
#> 420  105580001 105581000   900  17.59355248 105580500
#> 421  105581001 105582000   900 -11.11650520 105581500
#> 422  105582001 105583000   900 -31.96019682 105582500
#> 423  105583001 105584000   900 -29.63457841 105583500
#> 424  105584001 105585000   900  12.62901427 105584500
#> 425  105585001 105586000   900  10.31103267 105585500
#> 426  105586001 105587000   900  15.93917119 105586500
#> 427  105587001 105588000   900   4.18964007 105587500
#> 428  105588001 105589000   900   0.98026886 105588500
#> 429  105589001 105590000   900   5.83733660 105589500
#> 430  105590001 105591000   900  12.69241617 105590500
#> 431  105591001 105592000   900  20.61115210 105591500
#> 432  105592001 105593000   900  -4.27282794 105592500
#> 433  105593001 105594000   900 -22.73580421 105593500
#> 434  105594001 105595000   900  -2.30107758 105594500
#> 435  105595001 105596000   900  -2.19413234 105595500
#> 436  105596001 105597000   900  -1.81305442 105596500
#> 437  105597001 105598000   900 -12.37060400 105597500
#> 438  105598001 105599000   900   2.72751294 105598500
#> 439  105599001 105600000   900  -1.85990624 105599500
#> 440  105600001 105601000   900  -0.05844177 105600500
#> 441  105601001 105602000   900   4.12334959 105601500
#> 442  105602001 105603000   900  18.43536719 105602500
#> 443  105603001 105604000   900  20.82542344 105603500
#> 444  105604001 105605000   900  -7.98275297 105604500
#> 445  105605001 105606000   900  -6.94409891 105605500
#> 446  105606001 105607000   900  -5.41577171 105606500
#> 447  105607001 105608000   900  15.80476009 105607500
#> 448  105608001 105609000   900  -6.19834058 105608500
#> 449  105609001 105610000   900 -23.89097430 105609500
#> 450  105610001 105611000   900   1.12551923 105610500
#> 451  105611001 105612000   900   9.34990451 105611500
#> 452  105612001 105613000   900  -5.71123618 105612500
#> 453  105613001 105614000   900   7.29022707 105613500
#> 454  105614001 105615000   900  25.28009051 105614500
#> 455  105615001 105616000   900  -3.13149112 105615500
#> 456  105616001 105617000   900  -5.28130414 105616500
#> 457  105617001 105618000   900 -13.80102489 105617500
#> 458  105618001 105619000   900   3.68675888 105618500
#> 459  105619001 105620000   900  -3.76363783 105619500
#> 460  105620001 105621000   900 -16.78721108 105620500
#> 461  105621001 105622000   900  -1.06067784 105621500
#> 462  105622001 105623000   900   0.22457490 105622500
#> 463  105623001 105624000   900  -4.19834269 105623500
#> 464  105624001 105625000   900   0.37971999 105624500
#> 465  105625001 105626000   900 -22.16893229 105625500
#> 466  105626001 105627000   900  -5.25311723 105626500
#> 467  105627001 105628000   900  33.76371474 105627500
#> 468  105628001 105629000   900 -16.63378271 105628500
#> 469  105629001 105630000   900 -14.57547588 105629500
#> 470  105630001 105631000   900   9.13192980 105630500
#> 471  105631001 105632000   900  -7.04452011 105631500
#> 472  105632001 105633000   900  -0.71735844 105632500
#> 473  105633001 105634000   900  26.44851760 105633500
#> 474  105634001 105635000   900  18.70179181 105634500
#> 475  105635001 105636000   900   4.50725976 105635500
#> 476  105636001 105637000   900 -19.30447719 105636500
#> 477  105637001 105638000   900  -4.65574314 105637500
#> 478  105638001 105639000   900  -6.17873429 105638500
#> 479  105639001 105640000   900  -4.30979910 105639500
#> 480  105640001 105641000   900 -24.41189438 105640500
#> 481  105641001 105642000   900  -6.13650155 105641500
#> 482  105642001 105643000   900   2.52168886 105642500
#> 483  105643001 105644000   900   1.64161395 105643500
#> 484  105644001 105645000   900 -36.28397222 105644500
#> 485  105645001 105646000   900 -58.92714883 105645500
#> 486  105646001 105647000   900 -10.17920233 105646500
#> 487  105647001 105648000   900  -9.62233782 105647500
#> 488  105648001 105649000   900  20.99822883 105648500
#> 489  105649001 105650000   900  11.73011903 105649500
#> 490  105650001 105651000   900   9.80214057 105650500
#> 491  105651001 105652000   900 -49.98918950 105651500
#> 492  105652001 105653000   900 -11.37519316 105652500
#> 493  105653001 105654000   900 -12.92923043 105653500
#> 494  105654001 105655000   900   3.80939494 105654500
#> 495  105655001 105656000   900   3.56163064 105655500
#> 496  105656001 105657000   900  23.12204847 105656500
#> 497  105657001 105658000   900 -32.75441153 105657500
#> 498  105658001 105659000   900 -32.75441153 105658500
#> 499  105659001 105660000   900 -17.21034777 105659500
#> 500  105660001 105661000   900  -3.01146914 105660500
#> 501  105661001 105662000   900   0.00000000 105661500
#> 502  105662001 105663000   900  -6.78440222 105662500
#> 503  105663001 105664000   900 -20.67030049 105663500
#> 504  105664001 105665000   900 -69.68923843 105664500
#> 505  105665001 105666000   900   2.34995353 105665500
#> 506  105666001 105667000   900  23.81050848 105666500
#> 507  105667001 105668000   900 -63.17008292 105667500
#> 508  105668001 105669000   900 -59.02365602 105668500
#> 509  105669001 105670000   900 -35.68871493 105669500
#> 510  105670001 105671000   900 -14.05220925 105670500
#> 511  105671001 105672000   900  -4.99981642 105671500
#> 512  105672001 105673000   900  -3.74070935 105672500
#> 513  105673001 105674000   900 101.15053169 105673500
#> 514  105674001 105675000   900  60.41710809 105674500
#> 515  105675001 105676000   900  33.84882484 105675500
#> 516  105676001 105677000   900  34.75913762 105676500
#> 517  105677001 105678000   900  27.75579673 105677500
#> 518  105678001 105679000   900  18.57122380 105678500
#> 519  105679001 105680000   900  30.67333548 105679500
#> 520  105680001 105681000   900  13.09306098 105680500
#> 521  105681001 105682000   900  37.23479255 105681500
#> 522  105682001 105683000   900  47.61447449 105682500
#> 523  105683001 105684000   900  20.15126647 105683500
#> 524  105684001 105685000   900   1.12082079 105684500
#> 525  105685001 105686000   900   8.25112997 105685500
#> 526  105686001 105687000   900  13.24533718 105686500
#> 527  105687001 105688000   900  30.98937403 105687500
#> 528  105688001 105689000   900  15.76972807 105688500
#> 529  105689001 105690000   900  10.76407408 105689500
#> 530  105690001 105691000   900  22.70240214 105690500
#> 531  105691001 105692000   900  18.05208188 105691500
#> 532  105692001 105693000   900  -1.44555029 105692500
#> 533  105693001 105694000   900   0.37468258 105693500
#> 534  105694001 105695000   900   2.87344851 105694500
#> 535  105695001 105696000   900  23.01558346 105695500
#> 536  105696001 105697000   900  15.80741692 105696500
#> 537  105697001 105698000   900  -2.62127642 105697500
#> 538  105698001 105699000   900  12.63591355 105698500
#> 539  105699001 105700000   900  10.26047328 105699500
#> 540  105700001 105701000   900  28.30253177 105700500
#> 541  105701001 105702000   900   3.04535845 105701500
#> 542  105702001 105703000   900   1.16408505 105702500
#> 543  105703001 105704000   900   4.33915381 105703500
#> 544  105704001 105705000   900 -11.25324950 105704500
#> 545  105705001 105706000   900  -0.81390779 105705500
#> 546  105706001 105707000   900   3.21024324 105706500
#> 547  105707001 105708000   900 -11.02303666 105707500
#> 548  105708001 105709000   900 -10.29717814 105708500
#> 549  105709001 105710000   900  -3.43732539 105709500
#> 550  105710001 105711000   900  -3.63832833 105710500
#> 551  105711001 105712000   900  -0.13948218 105711500
#> 552  105712001 105713000   900   4.50046671 105712500
#> 553  105713001 105714000   900  -4.33409064 105713500
#> 554  105714001 105715000   900  11.44389879 105714500
#> 555  105715001 105716000   900   7.97291449 105715500
#> 556  105716001 105717000   900  -1.84612534 105716500
#> 557  105717001 105718000   900 -15.55782437 105717500
#> 558  105718001 105719000   900  -6.11444375 105718500
#> 559  105719001 105720000   900   6.64017921 105719500
#> 560  105720001 105721000   900  -5.48802747 105720500
#> 561  105721001 105722000   900 -11.96334741 105721500
#> 562  105722001 105723000   900 -14.71058904 105722500
#> 563  105723001 105724000   900 -11.20717957 105723500
#> 564  105724001 105725000   900  -5.97452869 105724500
#> 565  105725001 105726000   900  -2.94860894 105725500
#> 566  105726001 105727000   900  -5.34377286 105726500
#> 567  105727001 105728000   900  12.64057714 105727500
#> 568  105728001 105729000   900  -5.92790336 105728500
#> 569  105729001 105730000   900  13.01945979 105729500
#> 570  105730001 105731000   900  -4.02894482 105730500
#> 571  105731001 105732000   900  -2.15207943 105731500
#> 572  105732001 105733000   900   4.86498824 105732500
#> 573  105733001 105734000   900   3.49796149 105733500
#> 574  105734001 105735000   900  -5.57795820 105734500
#> 575  105735001 105736000   900   1.38526510 105735500
#> 576  105736001 105737000   900  -0.12408292 105736500
#> 577  105737001 105738000   900  -5.07222694 105737500
#> 578  105738001 105739000   900  -1.65260220 105738500
#> 579  105739001 105740000   900  -2.76701213 105739500
#> 580  105740001 105741000   900   1.00434418 105740500
#> 581  105741001 105742000   900  -8.49502221 105741500
#> 582  105742001 105743000   900  -6.14525956 105742500
#> 583  105743001 105744000   900   3.06715213 105743500
#> 584  105744001 105745000   900   0.08468998 105744500
#> 585  105745001 105746000   900  -8.29425939 105745500
#> 586  105746001 105747000   900   4.15101564 105746500
#> 587  105747001 105748000   900   4.17398167 105747500
#> 588  105748001 105749000   900  -3.18888053 105748500
#> 589  105749001 105750000   900  23.37650100 105749500
#> 590  105750001 105751000   900   4.31358200 105750500
#> 591  105751001 105752000   900   0.30285430 105751500
#> 592  105752001 105753000   900  -4.21370252 105752500
#> 593  105753001 105754000   900  -9.26146511 105753500
#> 594  105754001 105755000   900  -5.22929959 105754500
#> 595  105755001 105756000   900  -7.04108110 105755500
#> 596  105756001 105757000   900   0.77622503 105756500
#> 597  105757001 105758000   900   1.52669877 105757500
#> 598  105758001 105759000   900   8.10507113 105758500
#> 599  105759001 105760000   900  -0.51649830 105759500
#> 600  105760001 105761000   900  -3.27854496 105760500
#> 601  105761001 105762000   900   3.96599997 105761500
#> 602  105762001 105763000   900   7.54391106 105762500
#> 603  105763001 105764000   900   4.28745077 105763500
#> 604  105764001 105765000   900 -17.48702746 105764500
#> 605  105765001 105766000   900  -1.95622007 105765500
#> 606  105766001 105767000   900   3.72122575 105766500
#> 607  105767001 105768000   900 -12.52788978 105767500
#> 608  105768001 105769000   900   1.68628311 105768500
#> 609  105769001 105770000   900   3.96119650 105769500
#> 610  105770001 105771000   900  -3.78474102 105770500
#> 611  105771001 105772000   900  -0.15082259 105771500
#> 612  105772001 105773000   900   0.50330541 105772500
#> 613  105773001 105774000   900   0.96040258 105773500
#> 614  105774001 105775000   900   6.35645446 105774500
#> 615  105775001 105776000   900  -8.71783749 105775500
#> 616  105776001 105777000   900   9.96038764 105776500
#> 617  105777001 105778000   900   9.95221917 105777500
#> 618  105778001 105779000   900  -3.72572141 105778500
#> 619  105779001 105780000   900   1.43606282 105779500
#> 620  105780001 105781000   900   1.54475702 105780500
#> 621  105781001 105782000   900   3.08133604 105781500
#> 622  105782001 105783000   900   4.34172728 105782500
#> 623  105783001 105784000   900  17.36497225 105783500
#> 624  105784001 105785000   900  15.47767557 105784500
#> 625  105785001 105786000   900  -4.38009615 105785500
#> 626  105786001 105787000   900   7.14121111 105786500
#> 627  105787001 105788000   900   3.22996999 105787500
#> 628  105788001 105789000   900  -6.06601279 105788500
#> 629  105789001 105790000   900   3.09352925 105789500
#> 630  105790001 105791000   900 -12.06603847 105790500
#> 631  105791001 105792000   900   2.26756504 105791500
#> 632  105792001 105793000   900  -2.83718725 105792500
#> 633  105793001 105794000   900   3.71000833 105793500
#> 634  105794001 105795000   900   2.03345819 105794500
#> 635  105795001 105796000   900   6.36853674 105795500
#> 636  105796001 105797000   900   5.90721207 105796500
#> 637  105797001 105798000   900  -0.92629628 105797500
#> 638  105798001 105799000   900  17.84107627 105798500
#> 639  105799001 105800000   900  -0.33157627 105799500
#> 640  105800001 105801000   900  17.17612079 105800500
#> 641  105801001 105802000   900   4.04808673 105801500
#> 642  105802001 105803000   900  -6.66215535 105802500
#> 643  105803001 105804000   900  -3.55929277 105803500
#> 644  105804001 105805000   900   2.74594579 105804500
#> 645  105805001 105806000   900   3.78993175 105805500
#> 646  105806001 105807000   900   4.70218138 105806500
#> 647  105807001 105808000   900  20.59085785 105807500
#> 648  105808001 105809000   900   3.08768108 105808500
#> 649  105809001 105810000   900 -18.37484499 105809500
#> 650  105810001 105811000   900  -9.11062320 105810500
#> 651  105811001 105812000   900  -9.41306466 105811500
#> 652  105812001 105813000   900  -1.01972191 105812500
#> 653  105813001 105814000   900  -1.01972191 105813500
#> 654  105814001 105815000   900  -0.09933443 105814500
#> 655  105815001 105816000   900   4.04607270 105815500
#> 656  105816001 105817000   900  -1.97979092 105816500
#> 657  105817001 105818000   900   5.34348453 105817500
#> 658  105818001 105819000   900  -5.69619034 105818500
#> 659  105819001 105820000   900  -3.86136082 105819500
#> 660  105820001 105821000   900   9.08175001 105820500
#> 661  105821001 105822000   900  13.42393459 105821500
#> 662  105822001 105823000   900  -2.67862338 105822500
#> 663  105823001 105824000   900   9.32143904 105823500
#> 664  105824001 105825000   900   2.47533040 105824500
#> 665  105825001 105826000   900   6.10040547 105825500
#> 666  105826001 105827000   900  -2.42110658 105826500
#> 667  105827001 105828000   900   2.49597548 105827500
#> 668  105828001 105829000   900  -1.67786945 105828500
#> 669  105829001 105830000   900  -3.13379846 105829500
#> 670  105830001 105831000   900   0.63917882 105830500
#> 671  105831001 105832000   900  -8.05582278 105831500
#> 672  105832001 105833000   900  -1.97729541 105832500
#> 673  105833001 105834000   900   5.35706389 105833500
#> 674  105834001 105835000   900  -0.33874175 105834500
#> 675  105835001 105836000   900   1.71609570 105835500
#> 676  105836001 105837000   900  -5.75842608 105836500
#> 677  105837001 105838000   900   3.71911004 105837500
#> 678  105838001 105839000   900   0.16313737 105838500
#> 679  105839001 105840000   900   0.30900489 105839500
#> 680  105840001 105841000   900   0.29664469 105840500
#> 681  105841001 105842000   900   0.78629022 105841500
#> 682  105842001 105843000   900   0.48989920 105842500
#> 683  105843001 105844000   900   4.86529179 105843500
#> 684  105844001 105845000   900   3.98632666 105844500
#> 685  105845001 105846000   900  -0.10028316 105845500
#> 686  105846001 105847000   900  -0.06418122 105846500
#> 687  105847001 105848000   900   0.10963327 105847500
#> 688  105848001 105849000   900   0.91813004 105848500
#> 689  105849001 105850000   900   0.00000000 105849500
#> 690  105850001 105851000   900   0.62511688 105850500
#> 691  105851001 105852000   900  -3.16616403 105851500
#> 692  105852001 105853000   900   1.27111031 105852500
#> 693  105853001 105854000   900   5.59761468 105853500
#> 694  105854001 105855000   900  -0.31719192 105854500
#> 695  105855001 105856000   900   1.36908030 105855500
#> 696  105856001 105857000   900   1.19415687 105856500
#> 697  105857001 105858000   900   1.08557393 105857500
#> 698  105858001 105859000   900  -5.48681467 105858500
#> 699  105859001 105860000   900  -0.05841155 105859500
#> 700  105860001 105861000   900  -2.26982244 105860500
#> 701  105861001 105862000   900  -0.83970310 105861500
#> 702  105862001 105863000   900   0.00000000 105862500
#> 703  105863001 105864000   900   0.00000000 105863500
#> 704  105864001 105865000   900   2.09926249 105864500
#> 705  105865001 105866000   900 -12.81316445 105865500
#> 706  105866001 105867000   900   0.77696027 105866500
#> 707  105867001 105868000   900  -0.79657035 105867500
#> 708  105868001 105869000   900  -0.32838248 105868500
#> 709  105869001 105870000   900  -4.73206456 105869500
#> 710  105870001 105871000   900  -9.25187615 105870500
#> 711  105871001 105872000   900   2.68249695 105871500
#> 712  105872001 105873000   900  -1.00749419 105872500
#> 713  105873001 105874000   900   4.50480018 105873500
#> 714  105874001 105875000   900  -3.94012730 105874500
#> 715  105875001 105876000   900   6.08633552 105875500
#> 716  105876001 105877000   900  -8.58604531 105876500
#> 717  105877001 105878000   900   2.55481319 105877500
#> 718  105878001 105879000   900  10.34768860 105878500
#> 719  105879001 105880000   900  11.95873628 105879500
#> 720  105880001 105881000   900   6.02754472 105880500
#> 721  105881001 105882000   900  13.60859764 105881500
#> 722  105882001 105883000   900   1.23460174 105882500
#> 723  105883001 105884000   900  -1.55765881 105883500
#> 724  105884001 105885000   900  -3.58465766 105884500
#> 725  105885001 105886000   900  -2.63818468 105885500
#> 726  105886001 105887000   900  -0.31594484 105886500
#> 727  105887001 105888000   900  -4.11095723 105887500
#> 728  105888001 105889000   900  -4.92477263 105888500
#> 729  105889001 105890000   900   0.27329816 105889500
#> 730  105890001 105891000   900  -1.50629620 105890500
#> 731  105891001 105892000   900  -4.27653513 105891500
#> 732  105892001 105893000   900  -3.20080779 105892500
#> 733  105893001 105894000   900  -3.57963519 105893500
#> 734  105894001 105895000   900   1.51823617 105894500
#> 735  105895001 105896000   900   2.69598786 105895500
#> 736  105896001 105897000   900  -6.18370554 105896500
#> 737  105897001 105898000   900  -5.28648135 105897500
#> 738  105898001 105899000   900   5.17215146 105898500
#> 739  105899001 105900000   900   5.39053384 105899500
#> 740  105900001 105901000   900   0.80546223 105900500
#> 741  105901001 105902000   900  12.39011479 105901500
#> 742  105902001 105903000   900   4.14753609 105902500
#> 743  105903001 105904000   900   3.26192384 105903500
#> 744  105904001 105905000   900  10.27849761 105904500
#> 745  105905001 105906000   900   6.01509539 105905500
#> 746  105906001 105907000   900  -1.37584369 105906500
#> 747  105907001 105908000   900   3.66808192 105907500
#> 748  105908001 105909000   900  -3.39671933 105908500
#> 749  105909001 105910000   900  -2.51118985 105909500
#> 750  105910001 105911000   900  -6.05297667 105910500
#> 751  105911001 105912000   900  -5.99405046 105911500
#> 752  105912001 105913000   900  -3.91480063 105912500
#> 753  105913001 105914000   900  12.62467198 105913500
#> 754  105914001 105915000   900  -8.61280118 105914500
#> 755  105915001 105916000   900   1.50070500 105915500
#> 756  105916001 105917000   900  -2.07682571 105916500
#> 757  105917001 105918000   900  -4.16371378 105917500
#> 758  105918001 105919000   900  -0.16256739 105918500
#> 759  105919001 105920000   900   2.84573281 105919500
#> 760  105920001 105921000   900  -5.50368385 105920500
#> 761  105921001 105922000   900 -16.67466460 105921500
#> 762  105922001 105923000   900  -2.46887283 105922500
#> 763  105923001 105924000   900   0.28992030 105923500
#> 764  105924001 105925000   900   2.86598866 105924500
#> 765  105925001 105926000   900   6.51675886 105925500
#> 766  105926001 105927000   900  -4.42922098 105926500
#> 767  105927001 105928000   900  -4.27154021 105927500
#> 768  105928001 105929000   900  -2.96048690 105928500
#> 769  105929001 105930000   900   6.57523708 105929500
#> 770  105930001 105931000   900  -9.22952212 105930500
#> 771  105931001 105932000   900  -3.16016744 105931500
#> 772  105932001 105933000   900  -1.29013987 105932500
#> 773  105933001 105934000   900  -2.21068169 105933500
#> 774  105934001 105935000   900  -1.21353606 105934500
#> 775  105935001 105936000   900   0.12275941 105935500
#> 776  105936001 105937000   900   3.03344859 105936500
#> 777  105937001 105938000   900  -6.49455107 105937500
#> 778  105938001 105939000   900  -2.46458575 105938500
#> 779  105939001 105940000   900  -4.78182622 105939500
#> 780  105940001 105941000   900   1.38231491 105940500
#> 781  105941001 105942000   900   5.94460463 105941500
#> 782  105942001 105943000   900  -0.86682783 105942500
#> 783  105943001 105944000   900   0.00000000 105943500
#> 784  105944001 105945000   900   0.00000000 105944500
#> 785  105945001 105946000   900   0.00000000 105945500
#> 786  105946001 105947000   900   0.00000000 105946500
#> 787  105947001 105948000   900   0.00000000 105947500
#> 788  105948001 105949000   900  -3.98130871 105948500
#> 789  105949001 105950000   900  -1.43670141 105949500
#> 790  105950001 105951000   900   8.88538272 105950500
#> 791  105951001 105952000   900  -3.04079320 105951500
#> 792  105952001 105953000   900   0.31335869 105952500
#> 793  105953001 105954000   900 -14.99445482 105953500
#> 794  105954001 105955000   900   0.58227434 105954500
#> 795  105955001 105956000   900   0.24721992 105955500
#> 796  105956001 105957000   900   8.99770119 105956500
#> 797  105957001 105958000   900  10.37905471 105957500
#> 798  105958001 105959000   900  -6.16557697 105958500
#> 799  105959001 105960000   900 -10.00322646 105959500
#> 800  105960001 105961000   900  -0.45789841 105960500
#> 801  105961001 105962000   900  -3.74534085 105961500
#> 802  105962001 105963000   900  -0.77430871 105962500
#> 803  105963001 105964000   900  -1.12639269 105963500
#> 804  105964001 105965000   900  -1.90164055 105964500
#> 805  105965001 105966000   900  -1.14049352 105965500
#> 806  105966001 105967000   900  -1.14049352 105966500
#> 807  105967001 105968000   900   1.14658046 105967500
#> 808  105968001 105969000   900  -1.80834249 105968500
#> 809  105969001 105970000   900  -4.51490753 105969500
#> 810  105970001 105971000   900   7.20485907 105970500
#> 811  105971001 105972000   900   1.53900987 105971500
#> 812  105972001 105973000   900  -2.75706802 105972500
#> 813  105973001 105974000   900 -10.86431702 105973500
#> 814  105974001 105975000   900   2.49447033 105974500
#> 815  105975001 105976000   900   5.71984730 105975500
#> 816  105976001 105977000   900   0.39288321 105976500
#> 817  105977001 105978000   900   6.65090977 105977500
#> 818  105978001 105979000   900  -0.93592871 105978500
#> 819  105979001 105980000   900   1.78892121 105979500
#> 820  105980001 105981000   900  -0.47898488 105980500
#> 821  105981001 105982000   900   2.91604616 105981500
#> 822  105982001 105983000   900  -1.41664040 105982500
#> 823  105983001 105984000   900  -5.31092262 105983500
#> 824  105984001 105985000   900   3.04149341 105984500
#> 825  105985001 105986000   900   1.40255537 105985500
#> 826  105986001 105987000   900 -16.33052610 105986500
#> 827  105987001 105988000   900   1.92596612 105987500
#> 828  105988001 105989000   900   3.01537665 105988500
#> 829  105989001 105990000   900   6.74037466 105989500
#> 830  105990001 105991000   900  -0.10024602 105990500
#> 831  105991001 105992000   900  -1.19098146 105991500
#> 832  105992001 105993000   900  -3.25893941 105992500
#> 833  105993001 105994000   900  -0.84348740 105993500
#> 834  105994001 105995000   900  -2.47251603 105994500
#> 835  105995001 105996000   900  -1.37841333 105995500
#> 836  105996001 105997000   900  -6.17122090 105996500
#> 837  105997001 105998000   900  -3.18056723 105997500
#> 838  105998001 105999000   900   2.20531363 105998500
#> 839  105999001 106000000   900   1.50650078 105999500
#> 840  106000001 106001000   900   4.09009132 106000500
#> 841  106001001 106002000   900  -4.46501972 106001500
#> 842  106002001 106003000   900  -2.95728774 106002500
#> 843  106003001 106004000   900   1.55965253 106003500
#> 844  106004001 106005000   900   3.68044163 106004500
#> 845  106005001 106006000   900   0.38000278 106005500
#> 846  106006001 106007000   900  -0.42496518 106006500
#> 847  106007001 106008000   900  -3.88501217 106007500
#> 848  106008001 106009000   900  -0.99807129 106008500
#> 849  106009001 106010000   900   3.75045853 106009500
#> 850  106010001 106011000   900   1.53297825 106010500
#> 851  106011001 106012000   900   9.11956033 106011500
#> 852  106012001 106013000   900   0.69680688 106012500
#> 853  106013001 106014000   900  -1.86866606 106013500
#> 854  106014001 106015000   900  -1.86866606 106014500
#> 855  106015001 106016000   900  -4.97801729 106015500
#> 856  106016001 106017000   900 -23.07269182 106016500
#> 857  106017001 106018000   900  -0.99030326 106017500
#> 858  106018001 106019000   900  -4.18315419 106018500
#> 859  106019001 106020000   900  -3.82443234 106019500
#> 860  106020001 106021000   900  -1.90860835 106020500
#> 861  106021001 106022000   900   1.49593744 106021500
#> 862  106022001 106023000   900  -0.60744379 106022500
#> 863  106023001 106024000   900  -4.32783522 106023500
#> 864  106024001 106025000   900 -11.06546743 106024500
#> 865  106025001 106026000   900  -0.10188580 106025500
#> 866  106026001 106027000   900   1.15347809 106026500
#> 867  106027001 106028000   900   0.42520323 106027500
#> 868  106028001 106029000   900 -10.17381501 106028500
#> 869  106029001 106030000   900  -5.22148412 106029500
#> 870  106030001 106031000   900   5.31114043 106030500
#> 871  106031001 106032000   900   4.28687488 106031500
#> 872  106032001 106033000   900  -1.68851345 106032500
#> 873  106033001 106034000   900  -4.07567209 106033500
#> 874  106034001 106035000   900   6.07000404 106034500
#> 875  106035001 106036000   900  -0.21287417 106035500
#> 876  106036001 106037000   900 -14.41881047 106036500
#> 877  106037001 106038000   900  -5.65036291 106037500
#> 878  106038001 106039000   900 -10.15538384 106038500
#> 879  106039001 106040000   900  -2.29466650 106039500
#> 880  106040001 106041000   900 -17.03897841 106040500
#> 881  106041001 106042000   900 -15.11958304 106041500
#> 882  106042001 106043000   900 -33.50738191 106042500
#> 883  106043001 106044000   900   1.17524754 106043500
#> 884  106044001 106045000   900  -1.25432570 106044500
#> 885  106045001 106046000   900   1.44062393 106045500
#> 886  106046001 106047000   900  -0.82830530 106046500
#> 887  106047001 106048000   900   1.65702831 106047500
#> 888  106048001 106049000   900   3.66285167 106048500
#> 889  106049001 106050000   900   4.87790371 106049500
#> 890  106050001 106051000   900  -1.86114448 106050500
#> 891  106051001 106052000   900   1.47010750 106051500
#> 892  106052001 106053000   900  -3.35858583 106052500
#> 893  106053001 106054000   900   0.08378930 106053500
#> 894  106054001 106055000   900  -0.27228786 106054500
#> 895  106055001 106056000   900  -4.69264999 106055500
#> 896  106056001 106057000   900  -0.75077157 106056500
#> 897  106057001 106058000   900  -7.07273338 106057500
#> 898  106058001 106059000   900  -2.45406856 106058500
#> 899  106059001 106060000   900  -3.28803329 106059500
#> 900  106060001 106061000   900   8.99884286 106060500
#> 901  106061001 106062000   900  -5.44183681 106061500
#> 902  106062001 106063000   900  -3.36088332 106062500
#> 903  106063001 106064000   900   4.62570752 106063500
#> 904  106064001 106065000   900  -7.95195351 106064500
#> 905  106065001 106066000   900 -11.05617626 106065500
#> 906  106066001 106067000   900  -1.88622864 106066500
#> 907  106067001 106068000   900  -1.14970503 106067500
#> 908  106068001 106069000   900  -6.46198273 106068500
#> 909  106069001 106070000   900  -7.12796142 106069500
#> 910  106070001 106071000   900  -6.23822004 106070500
#> 911  106071001 106072000   900   2.62377185 106071500
#> 912  106072001 106073000   900  -0.52298767 106072500
#> 913  106073001 106074000   900   1.79058335 106073500
#> 914  106074001 106075000   900 -12.63210467 106074500
#> 915  106075001 106076000   900  -3.47463655 106075500
#> 916  106076001 106077000   900  -0.70928565 106076500
#> 917  106077001 106078000   900  -5.27505424 106077500
#> 918  106078001 106079000   900   8.32394267 106078500
#> 919  106079001 106080000   900   1.34534947 106079500
#> 920  106080001 106081000   900  -9.85752566 106080500
#> 921  106081001 106082000   900   2.55533612 106081500
#> 922  106082001 106083000   900   3.23096428 106082500
#> 923  106083001 106084000   900  -8.10232022 106083500
#> 924  106084001 106085000   900  -4.93087867 106084500
#> 925  106085001 106086000   900   4.03245783 106085500
#> 926  106086001 106087000   900  -7.13426941 106086500
#> 927  106087001 106088000   900  -2.49246902 106087500
#> 928  106088001 106089000   900  -8.52119075 106088500
#> 929  106089001 106090000   900   1.37212196 106089500
#> 930  106090001 106091000   900  -6.28299928 106090500
#> 931  106091001 106092000   900  -1.01314719 106091500
#> 932  106092001 106093000   900 -21.19201766 106092500
#> 933  106093001 106094000   900  -9.35656736 106093500
#> 934  106094001 106095000   900  -7.91660864 106094500
#> 935  106095001 106096000   900   4.82197557 106095500
#> 936  106096001 106097000   900 -14.46048135 106096500
#> 937  106097001 106098000   900  -3.75433738 106097500
#> 938  106098001 106099000   900  -5.12037607 106098500
#> 939  106099001 106100000   900  12.18426552 106099500
#> 940  106100001 106101000   900   0.90261554 106100500
#> 941  106101001 106102000   900   0.80648689 106101500
#> 942  106102001 106103000   900  -0.94864588 106102500
#> 943  106103001 106104000   900  -9.16406801 106103500
#> 944  106104001 106105000   900  -2.16775258 106104500
#> 945  106105001 106106000   900  -1.05855580 106105500
#> 946  106106001 106107000   900  -1.60006968 106106500
#> 947  106107001 106108000   900  -0.54422973 106107500
#> 948  106108001 106109000   900  -5.16729103 106108500
#> 949  106109001 106110000   900   3.06919322 106109500
#> 950  106110001 106111000   900  -0.86263993 106110500
#> 951  106111001 106112000   900  -1.76564818 106111500
#> 952  106112001 106113000   900  -5.10209312 106112500
#> 953  106113001 106114000   900  -0.15303609 106113500
#> 954  106114001 106115000   900   6.05325156 106114500
#> 955  106115001 106116000   900  10.32775073 106115500
#> 956  106116001 106117000   900   5.96260087 106116500
#> 957  106117001 106118000   900  -2.03309967 106117500
#> 958  106118001 106119000   900  -2.26355109 106118500
#> 959  106119001 106120000   900  -3.64722269 106119500
#> 960  106120001 106121000   900  -0.65966882 106120500
#> 961  106121001 106122000   900  -0.68403736 106121500
#> 962  106122001 106123000   900  -2.67963486 106122500
#> 963  106123001 106124000   900 -14.49038996 106123500
#> 964  106124001 106125000   900   1.43773489 106124500
#> 965  106125001 106126000   900  -1.00214629 106125500
#> 966  106126001 106127000   900  -2.67548708 106126500
#> 967  106127001 106128000   900  -0.84418564 106127500
#> 968  106128001 106129000   900  -4.04024560 106128500
#> 969  106129001 106130000   900  -0.93540401 106129500
#> 970  106130001 106131000   900   0.19033554 106130500
#> 971  106131001 106132000   900   0.34025787 106131500
#> 972  106132001 106133000   900  -9.02415964 106132500
#> 973  106133001 106134000   900  -1.27850430 106133500
#> 974  106134001 106135000   900  -2.33439438 106134500
#> 975  106135001 106136000   900   2.53663562 106135500
#> 976  106136001 106137000   900   1.83688649 106136500
#> 977  106137001 106138000   900  -0.03530281 106137500
#> 978  106138001 106139000   900   0.36434120 106138500
#> 979  106139001 106140000   900  -2.14572544 106139500
#> 980  106140001 106141000   900  -2.04454607 106140500
#> 981  106141001 106142000   900  -0.54210025 106141500
#> 982  106142001 106143000   900  -0.45546279 106142500
#> 983  106143001 106144000   900  -7.69146361 106143500
#> 984  106144001 106145000   900  -5.89847463 106144500
#> 985  106145001 106146000   900   1.53978839 106145500
#> 986  106146001 106147000   900   0.06800094 106146500
#> 987  106147001 106148000   900   0.33623294 106147500
#> 988  106148001 106149000   900   2.31461311 106148500
#> 989  106149001 106150000   900   1.75655118 106149500
#> 990  106150001 106151000   900  -1.12194536 106150500
#> 991  106151001 106152000   900  -2.29733164 106151500
#> 992  106152001 106153000   900  -1.25375339 106152500
#> 993  106153001 106154000   900  -1.38991321 106153500
#> 994  106154001 106155000   900   1.76369571 106154500
#> 995  106155001 106156000   900  -1.09647414 106155500
#> 996  106156001 106157000   900  -3.98084108 106156500
#> 997  106157001 106158000   900   2.79188678 106157500
#> 998  106158001 106159000   900 -10.23162365 106158500
#> 999  106159001 106160000   900 -15.29232188 106159500
#> 1000 106160001 106161000   900   0.19911058 106160500
#> 1001 106161001 106162000   900   6.82269228 106161500
#> 
#> $layers
#> $layers[[1]]
#> geom_col: just = 0.5, width = NULL, na.rm = FALSE
#> stat_identity: na.rm = FALSE
#> position_stack 
#> 
#> 
#> $scales
#> <ggproto object: Class ScalesList, gg>
#>     add: function
#>     add_defaults: function
#>     add_missing: function
#>     backtransform_df: function
#>     clone: function
#>     find: function
#>     get_scales: function
#>     has_scale: function
#>     input: function
#>     map_df: function
#>     n: function
#>     non_position_scales: function
#>     scales: list
#>     set_palettes: function
#>     train_df: function
#>     transform_df: function
#>     super:  <ggproto object: Class ScalesList, gg>
#> 
#> $guides
#> <Guides[0] ggproto object>
#> 
#> <empty>
#> 
#> $mapping
#> $x
#> <quosure>
#> expr: ^ctr
#> env:  global
#> 
#> $y
#> <quosure>
#> expr: ^delta
#> env:  global
#> 
#> $fill
#> <quosure>
#> expr: ^delta > 0
#> env:  global
#> 
#> attr(,"class")
#> [1] "uneval"
#> 
#> $theme
#> list()
#> 
#> $coordinates
#> <ggproto object: Class CoordCartesian, Coord, gg>
#>     aspect: function
#>     backtransform_range: function
#>     clip: on
#>     default: TRUE
#>     distance: function
#>     draw_panel: function
#>     expand: TRUE
#>     is_free: function
#>     is_linear: function
#>     labels: function
#>     limits: list
#>     modify_scales: function
#>     range: function
#>     render_axis_h: function
#>     render_axis_v: function
#>     render_bg: function
#>     render_fg: function
#>     reverse: none
#>     setup_data: function
#>     setup_layout: function
#>     setup_panel_guides: function
#>     setup_panel_params: function
#>     setup_params: function
#>     train_panel_guides: function
#>     transform: function
#>     super:  <ggproto object: Class CoordCartesian, Coord, gg>
#> 
#> $facet
#> <ggproto object: Class FacetNull, Facet, gg>
#>     attach_axes: function
#>     attach_strips: function
#>     compute_layout: function
#>     draw_back: function
#>     draw_front: function
#>     draw_labels: function
#>     draw_panel_content: function
#>     draw_panels: function
#>     finish_data: function
#>     format_strip_labels: function
#>     init_gtable: function
#>     init_scales: function
#>     map_data: function
#>     params: list
#>     set_panel_size: function
#>     setup_data: function
#>     setup_panel_params: function
#>     setup_params: function
#>     shrink: TRUE
#>     train_scales: function
#>     vars: function
#>     super:  <ggproto object: Class FacetNull, Facet, gg>
#> 
#> $plot_env
#> <environment: R_GlobalEnv>
#> 
#> $layout
#> <ggproto object: Class Layout, gg>
#>     coord: NULL
#>     coord_params: list
#>     facet: NULL
#>     facet_params: list
#>     finish_data: function
#>     get_scales: function
#>     layout: NULL
#>     map_position: function
#>     panel_params: NULL
#>     panel_scales_x: NULL
#>     panel_scales_y: NULL
#>     render: function
#>     render_labels: function
#>     reset_scales: function
#>     resolve_label: function
#>     setup: function
#>     setup_panel_guides: function
#>     setup_panel_params: function
#>     train_position: function
#>     super:  <ggproto object: Class Layout, gg>
#> 
#> $labels
#> $labels$title
#> [1] "Binned delta mean values for EsCells - Neurons"
#> 
#> $labels$x
#> [1] "ctr"
#> 
#> $labels$y
#> [1] "delta"
#> 
#> $labels$fill
#> [1] "delta > 0"
#> 
#> 
#> attr(,"class")
#> [1] "gg"     "ggplot"

Our interface carries out the binning inside the call to the function getSignificantRegions(). The delta data (here deltaSE) is then mined for significant regions.

The Algorithm

The algorithm proceeds as follows:

  1. The data is binned to smallBinSize (here 1kb) and trimmed to the region of interest. The region of interest here is 500kb up and downstream of the mid-point of the viewpoint.
  2. We now rebin this data to bigBinSize (here 10kb). This value should be an integer multiple of smallBinSize.
  3. The interaction count data are highest near the viewpoint. We therefore distinguish a viewpoint region.
    • In the viewpoint region, we compute the lopsidedness of the data, i.e., the absolute value of the difference between the sum of the bins to the left of the viewpoint and the sum of the bins to the right of the viewpoint.
    • Outside the viewpoint region we define runs to be maximal consecutive sequences of bins where the delta value does not change sign. We compute the totals of the bins in each run. We call these run totals.
  4. We now perform random permutations of the small-bin delta data.
    • Within the viewpoint region, these permutations respect the distance from the viewpoint. Thus, for each distance k from the viewpoint, the two bins at distance k either are or are not swapped.
    • We perform arbitrary permutations on the non-viewpoint bins.
  5. For each permutation, we rebin the resulting scrambled data to the large bin size and then compute the lopsidedness and run totals for that permutation.
  6. For each permutation we record the lopsidedness and maximum and minimum of the run totals. Across all permutations this produces
    • a distribution of lopsidedness values
    • a distribution of maximum run totals
    • a distribution of minimum run totals
  7. Significance in the original (unpermuted) data is then assessed by comparing the lopsidedness and run totals in the original data to these distributions.

Invoking the algorithm and plotting the results

significantRegions = getSignificantRegions(deltaSE,
                                           regionOfInterest,
                                           viewpointRegion,
                                           smallBinSize,
                                           bigBinSize,
                                           numPermutations,
                                           pValue)

which are then ploted using

library(deltaCaptureC)
significantRegionsPlot = plotSignificantRegions(significantRegions,
                                                significanceType,
                                                plotTitle)

This gives the following result:

#> NULL

Under the hood

Normalization

We have given an example above of the use of getDeltaSE(), converting miniSE into miniDeltaSE. This is a multi-step process, first normalizing the columns of miniSE, then averaging the values for each of the two treatments and finally taking their difference. For normalization, we relied on DESeq2::estimateSizeFactorsForMatrix().

library(SummarizedExperiment)
library(deltaCaptureC)
se = miniSE
counts = assays(se)[['counts']]
sizeFactors = DESeq2::estimateSizeFactorsForMatrix(counts)
colData(se)$sizeFactors = sizeFactors
assays(se)[['normalizedCounts']] = counts
for(i in seq_len(ncol(assays(se)[['normalizedCounts']])))
{
    assays(se)[['normalizedCounts']][,i] =
            assays(se)[['normalizedCounts']][,i] /
        colData(se)$sizeFactors[i]
}

Depending on your application, you may wish to use your own method of normalization.

The delta SummarizedExperiment is then the difference between the mean expressions for the two treatments.

library(SummarizedExperiment)
library(deltaCaptureC)
meanNormalizedCountsSE = getMeanNormalizedCountsSE(miniSE)
meanCounts = assay(meanNormalizedCountsSE)
delta = matrix(meanCounts[,1] - meanCounts[,2],ncol=1)
colData = data.frame(delta=sprintf('%s - %s',
                                    as.character(colData(meanNormalizedCountsSE)$treatment[1]),
                                    as.character(colData(meanNormalizedCountsSE)$treatment[2])),
                                    stringsAsFactors=FALSE)
deltaSE = SummarizedExperiment(assay=list(delta=delta),
                                          colData=colData)
rowRanges(deltaSE) = rowRanges(meanNormalizedCountsSE)

Binning

Binning is the rate-limiting step as can be seen from the binning of a small Summarized experiment into a small set of bins:

library(deltaCaptureC)
print(length(smallSetOfSmallBins))
#> [1] 201
print(length(smallerDeltaSE))
#> [1] 401
tictoc::tic('binning into small bins')
binnedSummarizedExperiment = binSummarizedExperiment(smallSetOfSmallBins,smallerDeltaSE)
tictoc::toc()
#> binning into small bins: 77.029 sec elapsed

The algorithm depends on the permutation of small bins and the rebinning of the resulting permuted data into large bins for comparison to the actual data binned into the same larger bins. The binning into smaller bins only happens once, while the rebinning into larger bins is carried out for each permutation. Consequently, we require the larger bin size to be an integer multiple of the smaller and this rebinning is much faster.

library(deltaCaptureC)
tictoc::tic('rebinning to larger bin size')
rebinnedSummarizedExperiment =
      rebinToMultiple(binnedSummarizedExperiment,10)
tictoc::toc()
#> rebinning to larger bin size: 0.18 sec elapsed