kaggle 中使用ipython

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了kaggle 中使用ipython相关的知识,希望对你有一定的参考价值。

# pandas
import pandas as pd
from pandas import Series,DataFrame

# numpy, matplotlib, seaborn
import numpy as np
import matplotlib.pyplot as plt
import seaborn as sns
sns.set_style(whitegrid)
%matplotlib inline

# machine learning
from sklearn.linear_model import LogisticRegression
from sklearn.svm import SVC, LinearSVC
from sklearn.ensemble import RandomForestClassifier
from sklearn.neighbors import KNeighborsClassifier
from sklearn.naive_bayes import GaussianNB

s = Series(np.random.randn(10).cumsum(), index=np.arange(0, 100, 10))
s.plot()

a=[1,2,3,4,5]
a

可以直接绘图:

技术分享

https://www.kaggle.com/bonelee/a-journey-through-titanic/editnb

以上是关于kaggle 中使用ipython的主要内容,如果未能解决你的问题,请参考以下文章