English | Portuguese (BR) |
---|---|
Provide | Provê |
Enhancement | Aprimoramento |
Enforce | Força |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Alias: | |
alias cpython="cd Workspace/cpython/" | |
alias kali="sudo docker container start kali-container && sudo docker exec -it kali-container /bin/bash" | |
alias stopkali="sudo docker container stop kali-container" | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def ApplyesKFold(x_axis, y_axis): | |
# Linear Models. | |
from sklearn.linear_model import LinearRegression | |
from sklearn.linear_model import ElasticNet | |
from sklearn.linear_model import Ridge | |
from sklearn.linear_model import Lasso | |
# Cross-Validation models. | |
from sklearn.model_selection import cross_val_score | |
from sklearn.model_selection import KFold |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import matplotlib.pyplot as plt | |
import pandas as pd | |
from sklearn.model_selection import cross_val_score # Cross Validation Function. | |
from sklearn.model_selection import KFold # KFold Class. | |
from sklearn.linear_model import LinearRegression # Linear Regression class. | |
df = pd.read_csv("../datasets/Admission_Predict.csv") | |
df.drop('Serial No.', axis = 1, inplace = True) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pandas as pd | |
pd.set_option('display.max_columns', 42) | |
data = pd.read_csv('../datasets/2015-building-energy-benchmarking.csv') | |
# Exibe a média de cada coluna. | |
print((data.isnull().sum() / len(data['OSEBuildingID'])) * 100, '\n') | |
data['ENERGYSTARScore'] = data['ENERGYSTARScore'].fillna(data['ENERGYSTARScore'].median()) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pandas as pd | |
pd.set_option('display.max_columns', 18) | |
data = pd.read_csv('../datasets/athlete_events.csv') | |
data['Height'] = data['Height'].fillna(data['Height'].mean()) | |
data['Weight'] = data['Weight'].fillna(data['Weight'].mean()) | |
print(data[['Height', 'Weight']].head(20)) |
NewerOlder