Exploring Dataset
import pandas as pd
loading data from file and set columns
df = pd.read_csv('imports-85.data')
columns = ['symboling', 'normalized-losses', 'make', 'fuel-type', 'aspiration', 'num-of-doors', 'body-style', 'drive-wheels', 'engine-location', 'wheel-base', 'length', 'width', 'height', 'curb-weight', 'engine-type', 'num-of-cylinders', 'engine-size', 'fuel-system', 'bore', 'stroke', 'compression-ratio', 'horsepower', 'peak-rpm', 'city-mpg', 'highway-mpg', 'price']
df.columns = columns
Checking data types
df.dtypes
Statistical summary
df.describe()
Full summary statistics
df.describe(include='all')
Concise summary
df.info()
Viewing top 5 rows
df.head()
Viewing bottom 5 rows
df.tail()
View dataset
df
Exporting dataset into csv file
df.to_csv('autos.csv')