Skip to content

Instantly share code, notes, and snippets.

View sgratzl's full-sized avatar

Samuel Gratzl sgratzl

View GitHub Profile
async function executeQuery(query) {
function sendJSON(url, body) {
return fetch(url, {
method: 'POST',
body: JSON.stringify(body),
credentials: 'same-origin',
headers: {
'kbn-version': '7.10.1',
'Content-Type': 'application/json'
}
interface IEllipse2D {
o: IVec2D;
rx: number;
ry: number;
rotation: number
}
/**
* Intersect two arbitrarily rotated ellipses. In the general case this boils down to solving a
@sgratzl
sgratzl / README.md
Created January 8, 2019 11:37
phovea2 a

f

@sgratzl
sgratzl / README.md
Last active September 19, 2019 01:59
Angular6 BoxPlot example
  1. create the app
npm install -g @angular/cli

# create a new app
ng new chart-app
cd chart-app
wrapdocker text eof=LF
<div class="lu">
<header>
<article></article>
<div class="slopegraph"></div>
</header>
<main>
<article></article>
<svg class="slopegraph"></svg>
</main>
</div>
@sgratzl
sgratzl / install_pathfinder.md
Created June 8, 2017 15:53
Installation instructions for pathfinder.caleydo.org

Install Pathfinder locally

prerequisites:

  • docker
  • docker-compose
  • node == v7
  • npm == v3
  • git command client
@sgratzl
sgratzl / index.html
Created November 23, 2016 19:17
phovea_provenance_hello_world
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Provenance Hello World</title>
</head>
<body>
<div class="clue_hello">
@sgratzl
sgratzl / lineup.json
Created April 21, 2016 09:36
Legatum Prosperity Index
{
"uid": 102,
"selection": [],
"rankings": [
{
"columns": [
{
"id": "col51",
"desc": {
"label": "Rank",
car mpg cyl disp hp drat wt qsec vs am gear carb
Mazda RX4 21 6 160 110 3.9 2.62 16.46 0 1 4 4
Mazda RX4 Wag 21 6 160 110 3.9 2.875 17.02 0 1 4 4
Datsun 710 22.8 4 108 93 3.85 2.32 18.61 1 1 4 1
Hornet 4 Drive 21.4 6 258 110 3.08 3.215 19.44 1 0 3 1
Hornet Sportabout 18.7 8 360 175 3.15 3.44 17.02 0 0 3 2
Valiant 18.1 6 225 105 2.76 3.46 20.22 1 0 3 1
Duster 360 14.3 8 360 245 3.21 3.57 15.84 0 0 3 4
Merc 240D 24.4 4 146.7 62 3.69 3.19 20 1 0 4 2
Merc 230 22.8 4 140.8 95 3.92 3.15 22.9 1 0 4 2