Skip to content

Instantly share code, notes, and snippets.

@joseph-allen
Created December 29, 2017 14:18
Show Gist options
  • Save joseph-allen/c98669a3a74a8ae21e5db23b02f6057f to your computer and use it in GitHub Desktop.
Save joseph-allen/c98669a3a74a8ae21e5db23b02f6057f to your computer and use it in GitHub Desktop.
Useful imports for a jupyter investigation
# Ignore warnings
import warnings
warnings.filterwarnings('ignore')
# Handle table-like data and matrices
import numpy as np
import pandas as pd
# Modelling Algorithms
from sklearn.tree import DecisionTreeClassifier
# Modelling Helpers
from sklearn.preprocessing import Imputer , Normalizer , scale
from sklearn.cross_validation import train_test_split , StratifiedKFold
from sklearn.feature_selection import RFECV
# Visualisation
import matplotlib as mpl
import matplotlib.pyplot as plt
import matplotlib.pylab as pylab
import seaborn as sns
# Configure visualisations
%matplotlib inline
mpl.style.use( 'ggplot' )
sns.set_style( 'white' )
pylab.rcParams[ 'figure.figsize' ] = 8 , 6
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment