# ---
# jupyter:
#   jupytext:
#     text_representation:
#       extension: .py
#       format_name: light
#       format_version: '1.5'
#       jupytext_version: 1.14.4
#   kernelspec:
#     display_name: Python 3
#     language: python
#     name: python3
# ---

# +
import numpy as np
import pandas as pd
import matplotlib.pylab as plt
import seaborn as sns

data1 = pd.read_csv('grizzlybearmortalityhistory_1976_2017.csv')
output = pd.concat([data1])
pd.DataFrame.from_dict(data1)
# -

data1.shape

data1.head

data1.columns

data1.describe().apply(lambda s: s.apply(lambda x: format(x, 'f')))

data1.nunique(axis=0)

data1.ID.unique()

data1.HUNT_YEAR.unique()

data1.MU.unique()

data1.GBPU_ID.unique()

data1.GBPU_NAME.unique()

data1.KILL_CODE.unique()

data1.SEX.unique()

data1.AGE_CLASS.unique()

data1.SPATIAL.unique()

corr = data1.corr()
sns.heatmap(corr, xticklabels=corr.columns, yticklabels=corr.columns, annot=True, cmap=sns.diverging_palette(220, 20, as_cmap=True))

data1.plot(kind='scatter', x='HUNT_YEAR', y='KILL_CODE')

data1.plot(kind='scatter', x='HUNT_YEAR', y='MU')

data1.plot(kind='scatter', x='HUNT_YEAR', y='SPATIAL')

data1.plot(kind='scatter', x='SEX', y='MU')

data1.plot(kind='scatter', x='MU', y='ID')

sns.pairplot(data1)

data1['HUNT_YEAR'].plot(kind='hist', bins=20, figsize=(15,10), facecolor='green',edgecolor='black')

data1['GBPU_ID'].plot(kind='hist', bins=20, figsize=(15,10), facecolor='yellow',edgecolor='black')

data1['MU'].plot(kind='hist', bins=20, figsize=(15,10), facecolor='blue',edgecolor='black')

# + tags=[]
data1.boxplot('HUNT_YEAR')
# -

data1.boxplot('GBPU_ID')

data1.boxplot('MU')

StarcoderdataJupyterScriptsDedupFiltered