Gmousse / dataframe-js

No Maintenance Intended
https://gmousse.gitbooks.io/dataframe-js/
MIT License
460 stars 38 forks source link

.push does not seem to work #120

Closed feiyu-london closed 3 years ago

feiyu-london commented 3 years ago

Hi, I am trying to test a few examples in the API to understand better how dataframe-js works. However, after .push a couple of arrays into df, console.log (df.count()) shows that the result is 0. Have I missed out anything obvious? Many thanks. Regards, Fei

const DataFrame = require('dataframe-js').DataFrame;

var h = ['a','b','c']; var d = [];

var df = new DataFrame(d,h); df.push([1,2,3],[4,5,6]); console.log (df.count());

feiyu-london commented 3 years ago

df = df.push([1,2,3],[4,5,6]); df.show(); this should work.