This file contains 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
<html> | |
<head> | |
<title>T.T. in GT Lab</title> | |
<meta http-equiv=content-type content="text/html; charset=utf-8"> | |
<link rel="stylesheet" type="text/css" href="http://yui.yahooapis.com/3.10.2/build/cssreset/cssreset-min.css"> | |
<style type="text/css"> | |
#query { | |
margin: 10px 0; | |
} | |
#controls { |
This file contains 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
<html> | |
<head> | |
<title>T.T. in GT Lab</title> | |
<meta http-equiv=content-type content="text/html; charset=utf-8"> | |
<link rel="stylesheet" type="text/css" href="http://yui.yahooapis.com/3.10.2/build/cssreset/cssreset-min.css"> | |
<style type="text/css"> | |
#query { | |
margin: 10px 0; | |
} | |
#controls { |
This file contains 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
var G_VARS = function () { | |
return { | |
S3_BUCKET_URL: "http://beloved.s3.amazonaws.com" | |
}; | |
}; | |
// usage: G_VARS().S3_BUCKET_URL |
This file contains 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
<html> | |
<head> | |
<link rel="stylesheet" href="http://yui.yahooapis.com/pure/0.2.1/grids-min.css"> | |
</head> | |
<body> | |
<div class="pure-g"> | |
<div class="pure-u-1-3"><p>Thirds</p></div> | |
<div class="pure-u-1-3"><p>Thirds</p></div> | |
<div class="pure-u-1-3"><p>Thirds</p></div> | |
</div> |
This file contains 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
X = [20.5156 12.0474 -12.1288 7.4995 38.9435 -4.5757 20.6246 19.6316 -7.3335 -2.6384 9.1368 24.2808 14.8241 15.9592 5.9249 19.085 -13.4054 -3.3012]; | |
Y = [4 5 5 3 2 3 5 2 3 2 5 4 4 1 6 6 6 6]; | |
[B, dev, stats] = mnrfit(X,Y, 'model', 'ordinal', 'interactions', 'off'); | |
% output: | |
% B = | |
% | |
% -3.3364 | |
% -1.6701 | |
% -0.8469 |
This file contains 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
X = [94.66 6.89 64.06 27.13 0.128356534 1770.99 10.96; ... | |
93.79 3.76 81.33 14.34 0.136729489 1509.71 25.79; ... | |
93.45 9.95 87.66 29.68 0.608227884 1425.85 45.61; ... | |
95.81 9.16 104.47 20.81 0.689591432 2285.79 22.86; ... | |
72.71 14.75 67.74 10.55 0.067760754 266.42 50.21; ... | |
94.11 11.92 74.25 14.17 0.172147321 1597.82 28.82; ... | |
81.19 4.14 84.28 15.67 0.085490275 431.63 28.65; ... | |
92.49 8.45 87.3 18.24 0.125981923 1232.12 44.27; ... | |
93.15 3.43 83.96 12.99 0.155595884 1360.22 37.87; ... | |
95.64 8.36 115.84 10.71 0.675068648 2195.31 24.09; ... |
This file contains 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
var tableArr = [ | |
"<p>line 1</p>", | |
"<p>line 2</p>", | |
"<p>line 3</p>" | |
], | |
key = 0; | |
for (key; key < tableArr.length; key = key + 1) { | |
(function (k) { | |
$('#line' + k).click(function (event) { |
This file contains 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
# 宣告變數 | |
if 1: | |
import random | |
EmptyBoard = [[0,0,0,0,0,0],[0,0,0,0,0,0],[0,0,0,0,0,0],[0,0,0,0,0,0],[0,0,0,0,0,0]] | |
Board = [[1, 2, 2, 2, 1, 1], [1, 2, 1, 2, 2, 2], [1, 2, 2, 1, 1, 1], [1, 1, 1, 1, 1, 1], [1, 1, 2, 1, 2, 2]] | |
CancelBoard = EmptyBoard | |
Comboing = 0 | |
Comboed =0 |
This file contains 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
/* | |
* The following code snippet runs in an angular controller body. | |
* It tries to convert a blob object "data" into data URL and bind the result to the scope. | |
* Fix it so that $scope.data will make UI change as expected. | |
*/ | |
/* global angular, data, FileReader */ | |
angular.module('xxx').controller('Ctrl', ['$scope', function ($scope) { | |
var reader = new FileReader(); |
This file contains 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
/* | |
* CJK Regex brought from http://apps.timwhitlock.info/js/regex | |
*/ | |
var CJKRegex = /[⺀-\u2efe\u3000-〾\u3040-ゞ゠-ヾ㇀-\u31eeㇰ-ㇾ㈀-㋾㌀-㏾㐀-\u4dbe一-\u9ffe豈-\ufafe︰-﹎]|[\ud840-\ud868\ud86a-\ud86c][\udc00-\udfff]|\ud82c[\udc00-\udcfe]|\ud869[\udc00-\udede\udf00-\udfff]|\ud86d[\udc00-\udf3e\udf40-\udfff]|\ud86e[\udc00-\udc1e]|\ud87e[\udc00-\ude1e]/; | |
/* | |
* Normalize display name for both Chinese and English names. | |
* @function | |
* @param {string} firstName |
OlderNewer