Skip to content

Instantly share code, notes, and snippets.

let percentageOfpopulation = x => (x / 17280000 * 100).toFixed(2) + "%"
let ifr = x => (16000 / x * 100).toFixed(3) + "%"
let days = 8
let prevalence = await fetch("https://data.rivm.nl/covid-19/COVID-19_prevalentie.json")
.then(response => response.json())
.then(data => data.reduce((acc, cur) => ({ low: acc.low + cur["prev_low"], high: acc.high + cur["prev_up"]}), {low: 0, high: 0}))
.then(data => ({ low: Math.round(data.low / days), high: Math.round(data.high / days)}))
@gsmeets
gsmeets / Profile-20180911T092703.json
Created September 11, 2018 07:28
canjs dynamic table
This file has been truncated, but you can view the full file.
[{"pid":17164,"tid":10068,"ts":607459478209,"ph":"X","cat":"toplevel","name":"ThreadControllerImpl::DoWork","args":{"src_file":"../../base/trace_event/trace_log.cc","src_func":"SetEnabled"},"dur":27,"tdur":26,"tts":3386318},
{"pid":17164,"tid":10068,"ts":607459478221,"ph":"F","cat":"toplevel","name":"RendererVisibility","args":{},"tts":3386329,"id":"0xafa0c35f4c95aa3b"},
{"pid":17164,"tid":10068,"ts":607459478221,"ph":"S","cat":"toplevel","name":"RendererVisibility","args":{},"tts":3386330,"id":"0xafa0c35f4c95aa3b"},
{"pid":17164,"tid":10068,"ts":607459478221,"ph":"T","cat":"toplevel","name":"RendererVisibility","args":{"step":"renderer_visible"},"tts":3386331,"id":"0xafa0c35f4c95aa3b"},
{"pid":17164,"tid":10068,"ts":607459478223,"ph":"F","cat":"toplevel","name":"RendererAudioState","args":{},"tts":3386332,"id":"0xafa0c35f4c95aa3b"},
{"pid":17164,"tid":10068,"ts":607459478224,"ph":"S","cat":"toplevel","name":"RendererAudioState","args":{},"tts":3386332,"id":"0xafa0c35f4c95aa3b"},
{"pid":17164,"tid":10068,"ts"
@gsmeets
gsmeets / ps-push-all-nuget-packages
Created October 16, 2017 22:39 — forked from bevand/ps-push-all-nuget-packages
Powershell push all packages from local folder
#add source
nuget sources Add -Name "custom-feed" -Source "https://newhostednugetfeed.com/custom-feed/nuget/v3/index.json" -username
USERNAME -password PASSWORD
$files = Get-ChildItem C:\LocalNuGetTest\*.nupkg
ForEach ($file in $files) {
#echo $file.fullName
nuget push -Source "custom-feed" -ApiKey VSTS $file.fullName
}
Scale Factors for Furtim_Active Damage Per Second
Agi AP Vers Crit Mastery Haste
Scale Factors 12.64 11.79 7.52 7.26 4.94 4.65
Normalized 1.00 0.93 0.60 0.57 0.39 0.37
Scale Deltas 1138 1138 1138 1138 1138 1138
Error 0.61 0.60 0.59 0.60 0.59 0.59
Gear Ranking wowhead
Optimizers askmrrobot
Ranking Agi > AP > Vers ~= Crit > Mastery ~= Haste
@gsmeets
gsmeets / example.js
Created May 30, 2015 00:01
RequireJS Stache loader plugin
define([
"can",
"stache!../views/SomeTemplate.stache"
], function ( can, VIEW ) {
// When creating a build layer stache file will be served up in an AMD define, wrapped in a can.stache call.
// At runtime the stache file is pulled in asynchronously as a dependency.
});