pandas

Original page (In Japanese): pandasでよく使う文法まとめ

read_csv

reading csv file
pandas.io.parsers.read_csv

options
index_col column for index
parse_dates column in datetime type
na_values missing value

to_csv

writing out csv file

dropna

delete the rows which have missing values

fillna

fill missing values by argument

interpolate

pandas.DataFrame.interpolate

  • method: {‘linear’, ‘time’, ‘index’, ‘values’, ‘nearest’, ‘zero’, ‘slinear’, ‘quadratic’, ‘cubic’, ‘barycentric’, ‘krogh’, ‘polynomial’, ‘spline’ ‘piecewise_polynomial’, ‘pchip’}

describe

show statistical summary of dataframe

groupby

grouping data
pandas.DataFrame.groupby

resample

compress data
pandas.DataFrame.resample

Making Dataframe by dist

print tip

Useful links