Skip to contents

Generate a fragment distance vector for your digested DNAString object

Usage

FROG_mix(my_DNA, pattern1 = "CATATG", pattern2 = "CGTGACTGGA")

Arguments

my_DNA,

That's your DNAString you aim to digest

pattern1,

The palindromic sequence pattern the restriction enzyme 1 recognizes

pattern2,

The non-PALINDROMIC nucleotide sequence pattern the restriction enzyme 2 recognizes

Value

A vector containing fragment lengths

Examples

my_DNA<-gen_DNA(1000)
pattern1<-'CATATG'
pattern2<-'CGTGACTGGA'
FROG_pal(my_DNA, pattern1, pattern2)
#> [1] 999

library(BSgenome.Hsapiens.UCSC.hg38)
#> Loading required package: GenomeInfoDb
#> Loading required package: BiocGenerics
#> 
#> Attaching package: ‘BiocGenerics’
#> The following objects are masked from ‘package:lubridate’:
#> 
#>     intersect, setdiff, union
#> The following objects are masked from ‘package:dplyr’:
#> 
#>     combine, intersect, setdiff, union
#> The following objects are masked from ‘package:stats’:
#> 
#>     IQR, mad, sd, var, xtabs
#> The following objects are masked from ‘package:base’:
#> 
#>     Filter, Find, Map, Position, Reduce, anyDuplicated, aperm, append,
#>     as.data.frame, basename, cbind, colnames, dirname, do.call,
#>     duplicated, eval, evalq, get, grep, grepl, intersect, is.unsorted,
#>     lapply, mapply, match, mget, order, paste, pmax, pmax.int, pmin,
#>     pmin.int, rank, rbind, rownames, sapply, setdiff, sort, table,
#>     tapply, union, unique, unsplit, which.max, which.min
#> Loading required package: S4Vectors
#> Loading required package: stats4
#> 
#> Attaching package: ‘S4Vectors’
#> The following objects are masked from ‘package:lubridate’:
#> 
#>     second, second<-
#> The following objects are masked from ‘package:dplyr’:
#> 
#>     first, rename
#> The following object is masked from ‘package:tidyr’:
#> 
#>     expand
#> The following object is masked from ‘package:utils’:
#> 
#>     findMatches
#> The following objects are masked from ‘package:base’:
#> 
#>     I, expand.grid, unname
#> Loading required package: IRanges
#> 
#> Attaching package: ‘IRanges’
#> The following object is masked from ‘package:lubridate’:
#> 
#>     %within%
#> The following objects are masked from ‘package:dplyr’:
#> 
#>     collapse, desc, slice
#> The following object is masked from ‘package:purrr’:
#> 
#>     reduce
#> The following object is masked from ‘package:grDevices’:
#> 
#>     windows
#> Loading required package: BSgenome
#> Loading required package: GenomicRanges
#> Loading required package: Biostrings
#> Loading required package: XVector
#> 
#> Attaching package: ‘XVector’
#> The following object is masked from ‘package:purrr’:
#> 
#>     compact
#> 
#> Attaching package: ‘Biostrings’
#> The following object is masked from ‘package:base’:
#> 
#>     strsplit
#> Loading required package: rtracklayer
chr1_Hsapiens<-BSgenome.Hsapiens.UCSC.hg38$chr1

FROG_pal(chr1_Hsapiens, pattern1, pattern2)
#>    [1] 11484 14896    94  1052  8944  2809  3333  1902  1418   214  1978   599
#>   [13]    15   802  1394  3492   784   711  4765  2617  1299  7774  1530  2330
#>   [25]   285  2992  6284  8574  2398  5704  5079   265  1991   184  3184  4936
#>   [37]   164   650  1994  2121 20944 13343   402   700 18794  1613  3166 14899
#>   [49]    94  1052  8941 51628  2154  5552  4625  2405  5685  5078   265  1991
#>   [61]   184  3186  4936   164   654  1994 50530  2156   984  4545  8136   574
#>   [73]   676  2850 14659  1328  7850  1148  4284  3432 12239  6927  2754   976
#>   [85]  1319  2094  1293  3310   772  3458   541  2270  7263   285   441   312
#>   [97]   421  3154  3695  3808 11210  4935   164   654  1996  2121 23540 13326
#>  [109]   402   700 18789 57094   574   676  2839 15496  1328  7850  1148  4276
#>  [121]  9302 12242  6911  2756   976  1319  2094  1293  3311   782  2685   541
#>  [133]  2270  7260   285   441   312   421  3154  3693  3805 11216  4936   164
#>  [145]   654  1995  2088 30326 13310   545   700 21988  4802  1361  3836  7962
#>  [157]   670   686   686    51   385  2431  3726   510   448   454  2590   991
#>  [169]   804  3395  8448   936  4055  3645 14480  2488  4614  2567   111  3672
#>  [181]  6496  5473  3161  2608  2163  2609 12897  4486 16211 27393 24494   493
#>  [193] 16349  1753  1147 39862 22992   271 22320  8232 20291 19559  7339 23124
#>  [205] 33021   771  1166  1072  2085  1857   570   984 10817 36061  8753 21649
#>  [217] 31781 13460  9643  2286   900  4649  5746  2100 22139 99867  1912 23779
#>  [229]  5029  7755 38691  3037 14226  5612 16361 10051 14065 14885  6074 20062
#>  [241]  1811  7972  3912 18223 35322  1722 10044 38170  2031 14721  5749  1619
#>  [253] 13836  3090   189  4251 17064 21734 12231  6328 20769  5602   190  5982
#>  [265] 32197  7439   702  1118  4127 30830  7154 21174  9645  2256 12782 10689
#>  [277] 45498 36889 22039   924 14325 26412 17207 19643 20914 10711  6750   981
#>  [289] 13084 70679  6704  4547  8481   285  1364  5807  2155  8355  2032 11305
#>  [301]   359    42    94 28667 11530   997 15551 10196  8731  8827  3149 77567
#>  [313]  8862 12123   679  1478 16363  7174   178   132   198  9307  8892  3192
#>  [325]   735 34840 18347 15777   887  1246 58818   887  1406  1932  1653  1495
#>  [337]   726  1456  1932  1813  1698   845   652  1797  9918  2775 26628   208
#>  [349] 23454   121  1829   277 17610 31293   117  3444   274  6365  5287  6872
#>  [361]   372    77   193   371  6519  6722  8332  6841 11862   776  5112 10057
#>  [373] 13474  6579   439  3801 17180   140  5673  6618  9054  3805   193 18674
#>  [385] 28409 14678  1090  5760  6053  4021 22996  4934  7154 20468  4924  2457
#>  [397]  7941  7688  1174  2831  2861 28911  4326  7866  2101  5983  1547   285
#>  [409]  8511  9807  4363    36 16148 15474  1400 10453   182   149   302   161
#>  [421] 14101   489   291   170   807  5620 16573 23916   100 12964  2059  2488
#>  [433]  3979  5413  9379  6041   223    40   255  6683  1781  9753  4405 13365
#>  [445]  1662  7201  2228  7686  5757 13058 10546 17385 24007 10755  8329    78
#>  [457] 13576   445   561    25 19032   142   232 20553 10357  1972  7155 10529
#>  [469]   807 12841 40815  1229 37269   295 10151  8348 18521 17653  8144  6964
#>  [481]  6298  3243  4801   583  3604  3642  3674  1929  3229 11663    92   330
#>  [493]  2867  1326   228  7445   468   312   211  4517  5392  6425 13458 10412
#>  [505]  1142  5879  7880   285  8617  2934 21799 10928   270 12116  1982   526
#>  [517]   689   725  9125  9335  5932 18585  4015  1698  4689   257 12007  3194
#>  [529]  1004 10975 11803   582 19135   285  4464    50  9394   713 36071  6150
#>  [541]   975  7379   111   430  5557 14474    77  5642  1322  2975   491  1203
#>  [553]  1616  3611   599  7790 15700  3384  2399  7460   578   397   754  1790
#>  [565]  8278  2806  4314  2669  4447  9833   211  2330   166   542  3809  2980
#>  [577]  2249    60  5685   300 17758  1174  3594  1247  7882  7403  1351 13038
#>  [589]  2197  1528 10676  1046   352 11382  4616  5146  4788    22   202  4000
#>  [601] 12374  1083  8800  3969  3612   526   221    54  1091   666  1687  6589
#>  [613]  7085  4843  2416   264   306 10824  7215   917   367  6295 15590  2281
#>  [625]  8307   395  2908   348  1451 23113  1310   338  4118  2286   275   711
#>  [637]  4313  3448   666  3226  2878  2842  6688  5188  6234   444   285 16499
#>  [649] 23273  2895  6345  8053    63  6244   773   460  3455  2108 12309 16896
#>  [661]  2975  1585 13601   903   142  7324   962 11047  8743 15232    88  4329
#>  [673]  3003  2482  5945  9782  4855  8942  3955    10  1976  1490  3701  2863
#>  [685]  2594   393 11093  4647   288  1480   534  4199 15388   381  6570  3155
#>  [697]  3852  2991  4353  5283  1151   285   786  4577   180  8444  2614  6351
#>  [709]   706   239   575  6949    14  9466  1481  7336  1301  2660  7512   760
#>  [721]  2666    90 12454    20    20    20    84    20    60    60  6738  5792
#>  [733] 15159 30190   653  4737  2451  3767   889  2377  4653  2946  7492  1642
#>  [745]  2385  1863  3601   140   336  4051  3123  4366  1142  5871  4806   260
#>  [757]  6283  9509  3712  4185    33  2443   345  1428  2129  4296  4690  2110
#>  [769]   691  1238  2685 13650 10734 13899  2875   927  8007  2153  7645  2793
#>  [781]  8420  3970  1301    19   902  1204  3300   118  5531  1901  2045  9170
#>  [793]   588  7477   921   309   112    86 11621  2671  2701   595  3400  2873
#>  [805]  4855  1874   958  6186    19  1768   187  3609  2030  2540  1528  1390
#>  [817]  4233  3369  3192  3505   135 15602  2825  2086  2878    36   629 13234
#>  [829]   603  3039  6806  5429  1973 16521  1563   906   581 17915   394  1390
#>  [841] 10209  3833  1034   111  4218 11693  1631 10441  2670  3627    41  2553
#>  [853] 15265  5177  7852  6528 12475 12605  3053  6305    18   120  2987  3563
#>  [865] 16499   968  4503  5108  2938    37  3479  3607   971  1971  1111  9882
#>  [877]  5947  6782  6313  4335  1951  4564  5487   867    99 14762  2677   266
#>  [889]  2996   155  6521  3074  3276   856   818  1145  1835   575   507  2047
#>  [901]   814   119  2498   734  3876  1807  4651  5109  1574   469  4418  2092
#>  [913]  1268 10104  2448  2224  3694  8657 13435  7367  4049 10558  1649  2284
#>  [925]  3176  2838  2457  3475   118 26946 15103  1540  2901    72  6339    75
#>  [937]    60  7578   201  3745   145  2328   421   265   422 12725  1999   285
#>  [949]  1148 14319 28620   131 10828 15083  3163  6549 16261   870   325  6021
#>  [961]   531    53   985  1837  4035 18922  1321  9796  5951  3232  3841  4469
#>  [973]   618 25840   758 12630  7485   183    64  2762    68    90    46  9615
#>  [985] 20204 11792  4897  7304  6537 24054  1835    32 18958   305 21688  3728
#>  [997]  2961  8317 22455 41915
#>  [ reached getOption("max.print") -- omitted 66489 entries ]