Permalink
Browse files

added ADX example

  • Loading branch information...
1 parent f2c059c commit 30132556f9b435786cfbe728e8a6b4f6a5a30087 @oransel committed Jan 27, 2012
Showing with 0 additions and 37 deletions.
  1. +0 −37 examples/demo.js
View
@@ -1,37 +0,0 @@
-var talib = require("../build/Release/talib");
-var fs = require("fs");
-
-console.log();
-console.log("TALib Version: " + talib.version);
-
-var marketContents = fs.readFileSync('examples/marketdata.json','utf8');
-var marketData = JSON.parse(marketContents);
-
-talib.execute({
- name: "AD",
- startIdx: 0,
- endIdx: marketData.close.length - 1,
- high: marketData.high,
- low: marketData.low,
- close: marketData.close,
- volume: marketData.volume
-}, function (result) {
- console.log();
- console.log("AD Function:");
- console.log(result);
-});
-
-talib.execute({
- name: "ADX",
- startIdx: 0,
- endIdx: marketData.close.length - 1,
- high: marketData.high,
- low: marketData.low,
- close: marketData.close,
- optInTimePeriod: 2
-}, function (result) {
- console.log();
- console.log("ADX Function:");
- console.log(result);
-});
-

0 comments on commit 3013255

Please sign in to comment.