데이터 분석/[Python] 기초
[Python] Pandas 옵션- 행/열 더 많이 보기
INCHELIN
2021. 7. 21. 15:52
728x90
pd.set_option('display.max_columns', 500) # 열(컬럼) 모두 보기
pd.set_option('display.max_rows', 500) # 행 모두 보기
데이터프레임을 print하여 콘솔에서 확인할 때, 행과 열이 일부만 보일 수 있습니다.
pd.get_option('display.max_columns') # 0
컬럼이 많아서 중간 컬럼들은 생략됩니다
pd.set_option('display.max_columns', 500)
모든 컬럼을 확인할 수 있습니다.
# option 초기화
pd.reset_option('display.max_columns')
728x90