parashift94
Reviews Written
12
Average Rating
4.4
Posts
Q&A
index ์ง๋ฌธ์ด์
df.index=df.index+1 ์ ๋ ๊ฒ์์ผ๋ก ์ฐพ์์ต๋๋ค....
- 0
- 1
- 205
Q&A
filter like
๊ฒ์ํด๋ณด๋, 'filter'๋ ๋ด์ฉ์ด ์๋๋ผ, ์ปฌ๋ผ์ ๋ํด ํํฐ๋ง ํ๋ ๋งค์๋๊ตฌ์.. str.contains ๋งค์๋๋ฅผ ์ฐ๋ฉด ์ํ์๋ ๋ต์ด ๋ ๋ฐ์ง ๋ชจ๋ฅด๊ฒ ๋ค์. df[df[name].str.contains(r'(^J)')] J๋ก ์์ํ๋ ๋จ์ด๋ฅผ ๋ฝ์ผ๋ ค๋ฉด, ์ ๊ทํํ์์ ์์ ๊ฐ์ด ์์ฑํ๋ฉด ๋ ๊ฒ ๊ฐ๋ค์...
- 0
- 1
- 328
Q&A
์ปฌ๋ผ๋ช ์ด ๋ค๋ฅผ ๊ฒฝ์ฐ ์ด๋ป๊ฒ ํฉ์น๋์?
df2์ ์ปฌ๋ผ๋ช ์ df1๊ณผ ๋์ผํ๊ฒ ์์ ํ, concatํ๋ฉด ์ด๋จ์ง์? df2.rename(columns={'์ด๋ฆ':'name', '์ง์ ':'job', inplace=True} result = pd.concat([df1, df2], ignore_index=True) ์๋๋ฉด, merge๋ฅผ ์จ์ผ ํ ๊ฒ ๊ฐ์๋ฐ, ์ข ๋ ๊ตฌ๊ธ๋ง ํ์๋ฉด ๋ ๊ฒ ๊ฐ๋ค์..
- 0
- 1
- 316
Q&A
input์ ์ด์ฉํด์ ์ํ๋ ํ ์ถ์ถ
name1 = input() df[df['name'] == name1]
- 0
- 1
- 285
Q&A
github cheetshitํ์ผ์ write dataframe to file ์ดํ๊ฐ ์ ๋ณด์ ๋๋ค. ์ ์ฒด ํ์ผ ๋ณผ ์ ์๋ ๋ฐฉ๋ฒ
ํ์ฌ ์ ๋ณด์ ๋๋ค.. ๊ทธ๋ฆฌ๊ณ , ๋ด์ฉ์ ๊ฐ์์๊ณผ ๋ณ ์ฐจ์ด๊ฐ ์๋ค์..
- 0
- 1
- 236
Q&A
ํ ์ฝ์
np.where(df['job'] != 'student', 'yes', 'no')
- 0
- 1
- 289
Q&A
if else ์ค๋ฅ
๊ฐ์์์๋ if row != 'F': ๋ผ๊ณ ํ์ จ๋๋ฐ, ์คํฌ๋ฆฐ์ท์ if row :='F': ๋ผ๊ณ ์ฐ์ ๊ฒ ๊ฐ๋ค์...
- 0
- 1
- 232




