oakscriptjs
v0.1.7
Published
PineScript v6 compatible technical analysis library for JavaScript/TypeScript
Maintainers
Readme
OakScriptJS is a TypeScript/JavaScript library that provides PineScript v6 compatible technical analysis functions. Build trading indicators, run backtests, or integrate TA calculations into any JavaScript environment.
Quick Start
Install
npm install oakscriptjsCalculate an indicator
import { Series, ta } from 'oakscriptjs';
const prices = [44, 44.5, 45, 45.5, 46, 46.5, 47, 47.5, 48, 48.5];
const close = new Series(prices);
const sma = ta.sma(close, 5);
console.log(sma.toArray());Documentation
- Guide — Getting started and core concepts
- Function Inventory — All available TA functions
Development
Prerequisites
- Node.js >= 18.0.0
Setup
npm install # Install dependencies
npm run build # Build
npm test # Run tests
npm run typecheck # Type checkProject Structure
oakscriptJS/
├── src/ # Source code
├── tests/ # Test suite
├── dist/ # Build output
└── docs/ # DocumentationMaintained by DeepEntropy
