-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathindex.html
More file actions
119 lines (94 loc) · 3.37 KB
/
index.html
File metadata and controls
119 lines (94 loc) · 3.37 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
<!doctype html>
<meta charset="UTF-8">
<html>
<head>
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.3.1/css/all.css" integrity="sha384-mzrmE5qonljUremFsqc01SB46JvROS7bZs3IO2EmfFsd15uHvIt+Y8vEf7N7fWAU" crossorigin="anonymous">
<link href="style.css" rel="stylesheet" >
</head>
<body style="margin: 0">
<!-- <h1 style="font: bold normal 1.8em sans-serif; margin: 20px">Genetics Genome Browser</h1> -->
<div id="info-line">
Powered by <a href=https://github.com/genenetwork/purescript-genetics-browser>genenetwork/purescript-genetics-browser</a>
</div>
<div id="browser">
<div id="controls">
<button id="scrollLeft" type="button" >
<i class="fas fa-arrow-left"></i>
</button>
<button id="scrollRight" type="button" >
<i class="fas fa-arrow-right"></i>
</button>
<button id="zoomOut" type="button" >
<i class="fas fa-search-minus"></i>
</button>
<button id="zoomIn" type="button" >
<i class="fas fa-search-plus"></i>
</button>
<button id="reset" type="button" >Reset</button>
</div>
</div>
<script src="./index.js"></script>
<script>
var localUrls =
{ snps: "./gwas.json",
annotations: "./annotations.json"
};
var urlRoot = "https://raw.githubusercontent.com/chfi/genetics-browser-example/master/track/data/";
var githubUrls =
{ snps: urlRoot + "gwas.json",
annotations: urlRoot + "annots_fake.json"
};
var vscaleWidth = 90.0;
var legendWidth = 140.0;
var score = { min: 0.0, max: 30.0, sig: 4 };
var gwasPadding = { top: 35.0,
bottom: 35.0,
left: vscaleWidth,
right: legendWidth };
var gwasHeight = 320.0;
var config =
{ score: score,
urls: localUrls,
tracks: {
gwas: {
trackHeight: gwasHeight,
padding: gwasPadding,
snps: {
radius: 3.75,
lineWidth: 1.0,
color: { outline: "#FFFFFF",
fill: "#00008B" },
pixelOffset: {x: 0.0, y: 0.0}
},
annotations: {
radius: 5.5,
outline: "#000000",
snpColor: "#0074D9",
geneColor: "#FF4136"
},
score: score,
legend: {
fontSize: 14,
hPad: 0.2,
vPad: 0.2
},
vscale: {
color: "#000000",
hPad: 0.125,
numSteps: 3,
fonts: { labelSize: 18, scaleSize: 16 }
},
},
},
chrs: {
chrBG1: "#FFFFFF",
chrBG2: "#EEEEEE",
chrLabels: { fontSize: 16 },
},
// initialChrs: { left: "1", right: "5" }
};
GenomeBrowser.main(config)();
document.getElementById("controls").style.visibility = "visible";
</script>
</body>
</html>