pandas-tspandas-ts
npm

pandas-ts is a TypeScript and JavaScript port of Python's pandas library. It provides familiar Series and DataFrame types for data manipulation, plus the entire pandas ecosystem: GroupBy, rolling windows, resampling, IO, and datetime support.

Math-heavy operations — histograms, quantiles, correlations, linear algebra — are powered by @cyfora/numera, the NumPy port with a C++ core.

Coverage#

AreaMethodsStatus
Series152+~95% parity
DataFrame134+~90% parity
Top-level pd.*30 functions✅
GroupBy30+ methods✅
Rolling / Expanding / EWM~20 each✅
.str accessor58 methods✅
.dt accessor45 methods✅
.cat accessor12 methods✅
IO28 functions✅
tseries.offsets16 classes✅
pd.testing4 functions✅

Quick example#

TypeScript
import pd, { read_csv } from 'pandas-ts';

// Read and explore
const df = read_csv('sales.csv');
df.head();
df.describe();

// Filter and group
const summary = df
  .loc(df.col('revenue').gt(1000))
  .groupby('region')
  .agg({ revenue: ['sum', 'mean'] });

// Time series
const dates = pd.date_range('2024-01-01', { periods: 12, freq: 'MS' });

Install#

Terminal
npm install pandas-ts

Get started → Browse the API →