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
| %========================================================================== | |
| % Exponentioal Moving Variance and the standard Variance comparison | |
| % Created by: Tiantian Xie (Dec. 10th, 2018) | |
| %========================================================================== | |
| clear; | |
| close all; | |
| NumberOfSamples = 500; | |
| X = rand(NumberOfSamples,1); | |
| WindowSize = 25; |
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
| // Pre-render d3 force-directed graph at server side | |
| // Call node pre_render_d3_graph.js to generate d3_graph.html | |
| // Original idea and framework borrowed from https://gist.github.com/mef/7044786 | |
| var d3 = require('d3') | |
| , jsdom = require('jsdom') | |
| , fs = require('fs') | |
| , htmlStub = '<html><head> \ | |
| <style>.node { stroke: #fff; fill: #ccc; stroke-width: 1.5px; } \ | |
| .link { stroke: #333; stroke-opacity: .5; stroke-width: 1.5px; }</style> \ |
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
| /* | |
| * Example code of read sensor data of multiple SensorTag (CC2541DK-SENSOR, CC2650STK) at same time by using node-sensortag | |
| * | |
| * Node.js 0.10.36 or higher (4.4.2 ready) | |
| * | |
| * Usage; | |
| * $ npm install sensortag async | |
| * $ node multiple_sensortag.js | |
| * | |
| * e.g.) |
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
| # Something in lines of http://stackoverflow.com/questions/348630/how-can-i-download-all-emails-with-attachments-from-gmail | |
| # Make sure you have IMAP enabled in your gmail settings. | |
| # Right now it won't download same file name twice even if their contents are different. | |
| import email | |
| import getpass, imaplib | |
| import os | |
| import sys | |
| detach_dir = '.' |