Skip to content

Instantly share code, notes, and snippets.

Parul Pandey parulnith

Block or report user

Report or block parulnith

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@parulnith
parulnith / README-Template.md
Last active Jun 7, 2019 — forked from PurpleBooth/README-Template.md
A template to make good README.md
View README-Template.md

Project Title

One Paragraph of project description goes here

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

View exploring_boston.py
,CRIM,ZN,INDUS,CHAS,NOX,RM,AGE,DIS,RAD,TAX,PTRATIO,B,LSTAT
0,0.00632,18,2.31,0,0.538,6.575,65.2,4.09,1,296,15.3,396.9,4.98
1,0.02731,0,7.07,0,0.469,6.421,78.9,4.9671,2,242,17.8,396.9,9.14
2,0.02729,0,7.07,0,0.469,7.185,61.1,4.9671,2,242,17.8,392.83,4.03
3,0.03237,0,2.18,0,0.458,6.998,45.8,6.0622,3,222,18.7,394.63,2.94
4,0.06905,0,2.18,0,0.458,7.147,54.2,6.0622,3,222,18.7,396.9,5.33
View wine_data_correlation.csv
We can make this file beautiful and searchable if this error is corrected: It looks like row 2 should actually have 5 columns, instead of 1. in line 1.
fixed acidity,volatile acidity,citric acid,residual,sugar chlorides free sulfur dioxide total sulfur dioxide density pH sulphates alcohol quality
1 -0.0226973 0.289181 0.0890207 0.0230856 -0.0493959 0.0910698 0.265331 -0.425858 -0.017143 -0.120881 -0.113663
-0.0226973 1 -0.149472 0.0642861 0.0705116 -0.0970119 0.0892605 0.0271138 -0.0319154 -0.0357281 0.0677179 -0.194723
0.289181 -0.149472 1 0.0942116 0.114364 0.0940772 0.121131 0.149503 -0.163748 0.0623309 -0.0757287 -0.00920909
0.0890207 0.0642861 0.0942116 1 0.0886845 0.299098 0.401439 0.838966 -0.194133 -0.0266644 -0.450631 -0.0975768
0.0230856 0.0705116 0.114364 0.0886845 1 0.101392 0.19891 0.257211 -0.0904395 0.0167629 -0.360189 -0.209934
-0.0493959 -0.0970119 0.0940772 0.299098 0.101392 1 0.615501 0.29421 -0.000617796 0.0592172 -0.250104 0.00815807
0.0910698 0.0892605 0.121131 0.401439 0.19891 0.615501 1 0.529881 0.00232097 0.134562 -0.448892 -0.174737
0.265331 0.0271138 0.149503 0.838966 0.257211 0.29421 0.529881 1 -0.0935915 0.0744931 -0.780138 -0.30
View eda.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View celluloid_legends.py
import matplotlib
from matplotlib import pyplot as plt
from celluloid import Camera
fig = plt.figure()
camera = Camera(fig)
for i in range(20):
t = plt.plot(range(i, i + 5))
plt.legend(t, [f'line {i}'])
camera.snap()
View celluloid_subplots.py
import numpy as np
from matplotlib import pyplot as plt
from celluloid import Camera
fig, axes = plt.subplots(2)
camera = Camera(fig)
t = np.linspace(0, 2 * np.pi, 128, endpoint=False)
for i in t:
axes[0].plot(t, np.sin(t + i), color='blue')
axes[1].plot(t, np.sin(t - i), color='blue')
View celluloi_minimal.py
from matplotlib import pyplot as plt
from celluloid import Camera
fig = plt.figure()
camera = Camera(fig)
for i in range(10):
plt.plot([i] * 10)
camera.snap()
animation = camera.animate()
animation.save('celluloid_minimal.gif', writer = 'imagemagick')
View 3d_animation.py
# library
from mpl_toolkits.mplot3d import Axes3D
import matplotlib.pyplot as plt
import pandas as pd
import seaborn as sns
# Get the data (csv file is hosted on the web)
url = 'https://python-graph-gallery.com/wp-content/uploads/volcano.csv'
data = pd.read_csv(url)
View live_graph.py
#importing libraries
import matplotlib.pyplot as plt
import matplotlib.animation as animation
fig = plt.figure()
#creating a subplot
ax1 = fig.add_subplot(1,1,1)
def animate(i):
You can’t perform that action at this time.