Skip to content

Instantly share code, notes, and snippets.

View sukanyabag's full-sized avatar
🌴
On vacation

Sukanya Bag sukanyabag

🌴
On vacation
View GitHub Profile
@sukanyabag
sukanyabag / Importing libraries
Created August 13, 2020 17:07
Importing pandas and sweetviz library
#import the pandas and sweetviz library. Make sure both are installed in your system properly.
# if not, pass the command 'pip install pandas' and 'pip install sweetviz'
import pandas as pd
import sweetviz
@sukanyabag
sukanyabag / loading datasets
Created August 13, 2020 17:16
Loading the train and test datasets
#load the train and test datasets using pandas
train = pd.read_csv("train.csv")
test = pd.read_csv("test.csv")
@sukanyabag
sukanyabag / Print 1st and last 5 rows to check
Created August 13, 2020 17:19
PRINT HEAD AND TAIL OF DATASET
#check the 1st 5 rows
train.head()
#check the last 5 rows
train.tail()
@sukanyabag
sukanyabag / analyzing single dataframe (train)
Created August 13, 2020 17:29
Analyzing a single dataframe
#create a variable called report.
report = sweetviz.analyze([train,"Train"], target_feat = 'SalePrice')
# creating the report as a html file to view and study the exploratory data analysis.
report.show_html('Report.html')
@sukanyabag
sukanyabag / Comparative advanced eda with two features
Created August 13, 2020 17:38
comparative eda of two datasets
# sweetviz's compare function helps to compare and make eda on two or more features
report1 = sweetviz.compare([train,"Train"],[test,"Test"], "SalePrice")
# generating the interactive html report; this gets automatically saved to your folder
report1.show_html('Report1.html')
y(t) = Level + Trend + Seasonality + Noise
y(t) = Level * Trend * Seasonality * Noise
import pandas as pd
import os
import shutil
# create a data for the covid +ve samples (ieee real world dataset)
FILE_PATH = "covid-chestxray-dataset-master/metadata.csv"
IMAGES_PATH = "covid-chestxray-dataset-master/images"
df = pd.read_csv(FILE_PATH)
print(df.shape)
df = pd.read_csv(FILE_PATH)
print(df.shape)
df = pd.read_csv(FILE_PATH)
print(df.shape)