8000 GitHub - yhay81/mcmder: Yet Another Wrapper of Nysol M-Command in Python; High-speed processing of large CSV.
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

yhay81/mcmder

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Rep A1CC ository files navigation

mcmder

Yet Another Wrapper of Nysol M-Command in Python.

Description

High-speed processing (CSV) of large-scale structured data tables.

To know more about Nysol and M-Command, see the official documents.

What is Nysol and M-Command?

Nysol Official Page

M-Command GitHub

How fast Nysol is?

Nysol Biz Page (Japanese)

Features

  • Create M-Command easily in python with method chaining.
  • Execute M-Command without putting large data on memory.(csv to csv)
  • Optionally use pandas DataFrame as input and output.

Requirement

Install

pip install mcmder

Usage

From CSV File

sample.csv

a,b,c
x,1,4
y,2,9
z,3,3
>>> from mcmder import Mcmder
>>> m = Mcmder('sample.csv')
>>> mc = m.mcut(['a','c'])
>>> mc.save('cut.csv')

cut.csv

a,c
x,4
y,9
z,3
>>> mc.dataframe
   a  c
0  x  4
1  y  9
2  z  3

From pandas DataFrame

>>> from mcmder import Mcmder
>>> import pandas as pd
>>> import numpy as np
>>> df = pd.DataFrame(np.random.randn(6,4), columns=list('ABCD'))
>>> m = Mcmder(df)
>>> mc = m.mcut(['A','C','D']).msel('${A}>0')
>>> mc.dataframe
          A         C         D
0  0.251857  0.080099 -1.211923
1  0.100167 -1.824585  0.051611
2  0.890079  1.440997 -0.298709

License

MIT

Author

Yusuke Hayashi

About

Yet Another Wrapper of Nysol M-Command in Python; High-speed processing of large CSV.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

0