First commit
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
//Finds an unknown point distance L along a quadratic curve from a known point. | |
//Alex Pilafian 2017 - [email protected] - github.com/sikanrong | |
//If you reuse this code please give me attribution, my dude! I worked hard on this. | |
//parabola defined by ax^2 + bx + c, a and b are passed in to constructor while c is omitted because it isn't relevant to our calculations. | |
//u is known point x-value | |
//L is known length to travel down the curve for our unknown point. | |
//v is the unknown point x-value, once we have v we can calculate the correspondiing unknown y just by pluging it | |
//back into our parabola function |
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
class DataController | |
def normalize | |
@result = "" | |
file = File.open("params", "w") | |
file << params[:data] | |
file.close | |
`iconv -c -f UTF-8 -t WINDOWS-1251 params > in` | |
`./mystem -l in out` | |
`iconv -c -f WINDOWS-1251 -t UTF-8 out > result` | |
file = File.open("result", "r") |
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
import _ from 'lodash' | |
const o = { | |
a: 1, | |
b: { | |
c: 2 | |
} | |
} | |
const getKeysDeep = o => ( |
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
class File | |
def to_string | |
string = '' | |
self.each {|line| | |
string << line | |
} | |
return string | |
end | |
end |
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
#!/usr/bin/env node | |
var fs = require('fs') | |
, wrench = require('wrench') | |
//works under linux | |
//, parser = require('xml2json') | |
, path = process.cwd() | |
_ = require('lodash') | |
var test = function(files){ |
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
#!/usr/bin/env node | |
var inputFolder = './'; | |
var ext = '.png'; | |
var fs = require('fs') | |
, gm = require('gm') | |
, spawn = require('child_process').spawn; | |
//gm(inputFolder + '0-0.png') |
This fork of axis example use changed D3's axis component. The goal of rewrite is to incapsulate all module functionality in one object.