일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | ||||
4 | 5 | 6 | 7 | 8 | 9 | 10 |
11 | 12 | 13 | 14 | 15 | 16 | 17 |
18 | 19 | 20 | 21 | 22 | 23 | 24 |
25 | 26 | 27 | 28 | 29 | 30 | 31 |
- 카카오APi
- #비정형#카카오api#api#크롤링
- 파이썬 셀레니움
- #비정형 데이터 #네이버 #지도 #크롤링
- #K-means #Clustering
- 구글 지오코드
- #위도#경도#비정형데이터#크롤링
- 숫자빼고 중복되는 코드동작법
- #크롤링 #웹문서
- 코딩
- 웹크롤링
- 셀레니움
- 위도경도
- 파이썬
- 웹매크로 #세잔느
- Today
- Total
목록All (143)
지방이의 Data Science Lab
1 2 3 4 5 def change_day(day_list): change = np.where(day_list == 28, 1, day_list+1) return change
from sklearn.preprocessing import MinMaxScaler scaler = MinMaxScaler(copy=True, feature_range=(0, 1)) temp = label.iloc[:, 1:] scaler.fit_transform(temp.values)from sklearn.preprocessing import MinMaxScaler scaler = MinMaxScaler(copy=True, feature_range=(0, 1)) temp = label.iloc[:, 1:] temp = pd.DataFrame(scaler.fit_transform(temp.values)) temp.columns = label.iloc[:,1:].columns temp=pd.concat([..
test2_act['week'] = np.floor((test2_act['day'] -1)/ 7 +1 ) temp['dayofweek'] = temp['day'] % 7 + 1
def resumetable(df): print(f"Dataset Shape: {df.shape}") summary = pd.DataFrame(df.dtypes,columns=['dtypes']) summary = summary.reset_index() summary['Name'] = summary['index'] summary = summary[['Name','dtypes']] summary['Min'] = df.min().values summary['Max'] = df.max().values summary['Missing'] = df.isnull().sum().values summary['Uniques'] = df.nunique().values return summary train_label = pd..
temp = pd.merge(final, train_activity.groupby('acc_id')['npc_kill'].sum().to_frame('is_npc_kill').reset_index(), on ='acc_id', how='left') temp['is_npc_kill'] = np.where(temp['is_npc_kill']==0, 1, 0)

import matplotlib.pyplot as plt import matplotlib.image as mpimg image = mpimg.imread("map.png") plt.figure(figsize = (100,50)) plt.imshow(image) #plt.show()
1 2 3 4 5 6 7 from sklearn.model_selection import train_test_split from sklearn.model_selection import GroupShuffleSplit train_inds, test_inds=next(GroupShuffleSplit(test_size=.2,n_splits=2,random_state=7).split(data,groups=data['acc_id'])) train=data.iloc[train_inds] test=data.iloc[test_inds] Colored by Color Scripter