학습 log (이론)/python10 '통계 분석' 평균 (Mean) 데이터들의 합 / 데이터 개수 중간값 (Median) 오름차순 정렬한 다음, 홀 수개 일 때는 가운데 값 짝 수개 일 때는 가운데 두 값을 더 한 다음 나누기 2한 결과값 *평균에 비해서 잘 못 된 값에 대한 영향을 적게 받는 특성을 가짐 상관 계수 (Correlation Coefficient) X와 Y의 상관관계를 수치화 Pearson Correlation Coefficient -1 ~ 1 까지의 값을 가지는 상관 계수 0 -> 1 : 정관계 방향, 1에 가까울수록 연관성 높음 0 -> -1 : 역관계 방향, -1에 가까울수록 연관성 높음 %matplotlib inline import pandas as pd import seaborn as sb df = pd.read_csv('exam.. 2020. 3. 4. 'Seaborn' Seaborn 통계를 기반으로한 시각화 http://seaborn.pydata.org/ seaborn: statistical data visualization — seaborn 0.10.0 documentation Seaborn is a Python data visualization library based on matplotlib. It provides a high-level interface for drawing attractive and informative statistical graphics. For a brief introduction to the ideas behind the library, you can read the introductory note seaborn.pydata.org 확률.. 2020. 3. 4. '시각화' 선그래프 수치를 보여주기 위한 그래프 (변화 파악) X축: 시간 관련 값 , Y축: 관찰하고 싶은 값 %matplotlib inline import pandas as pd df=pd.read_csv('broad.csv', index_col=0) df.plot(kind='line') #그래프 종류 선택, default: line 생략가능 df.plot(y=['컬럼1', '컬럼2']) #특정 값만 보기1 df[['컬럼1', '컬럼2']].plot #특정 값만 보기2 막대그래프 다양한 카테고리를 특정기준으로 비교하기 위한 그래프 (항목 비교) %matplotlib inline import pandas as pd df=pd.read_csv('sports.csv', index_col=0) df.plot(kind=.. 2020. 3. 3. 'pandas' 데이터 프레임 import pandas as pd Numpy를 상속하여 구현된 라이브러리 *Numpy의 기능 모두 지원 외부 데이터를 간편하게 읽고 쓰기 DataFrame 데이터 보관 / 정리 / 시각적 분석 *DataFrame: 표형식의 데이터 구조 (데이터 특징을 나타내는 Column과 각 객체를 나타내는 Row로 구성) int64: 정수 / float64: 소수 / object: 텍스트 / bool: 참, 거짓 / datetime64: 날짜, 시간 / category: 카테고리 Pandas 기본 사용법 import numpy as np #numpy 추가 import pandas as pd #pandas 추가 lists = [['illua', 25],['blog', 30]] # 기본 데이터 생성방법1 ids = [.. 2020. 3. 1. 이전 1 2 3 다음