This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function assertNotEmpty(list) { | |
if (list.length === 0) | |
throw new Error("List length is zero"); | |
} | |
function simple_exponential_smoothing(series, alpha) { | |
assertNotEmpty(series); | |
var prev = 0.0; | |
var ses_series = []; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
String.prototype.extract = function(prefix, suffix) { | |
s = this; | |
var i = s.indexOf(prefix); | |
if (i >= 0) { | |
s = s.substring(i + prefix.length); | |
} | |
else { | |
return ''; | |
} | |
if (suffix) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ul.tree, ul.tree ul { | |
list-style: none; | |
margin: 0; | |
padding: 0; | |
} | |
ul.tree ul { | |
margin-left: 10px; | |
} | |
ul.tree li { | |
margin: 0; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!doctype html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8"> | |
<title>Simple jQuery Infinite Scroll</title> | |
</head> | |
<body> | |
<h1>One</h1> | |
<br /> |