15. 판다스의 시리즈와 데이터프레임을 임포트하기
>>> from pandas import Series, DataFrame >>> s = Series([0.1, 1.2, 2.3, 3.4, 4.5], index = ['a', 'b', 'c', 'd', 'e']) >>> s['a'] 0.1 >>> s[0] 0.1 >>> s[['a', 'c']] a 0.1 c 2.3 dtype: float64 >>> s[[0, 2]] a 0.1 c 2.3 dtype: float64 >>> s[s > 2] c 2.3 d 3.4 e 4.5 dtype: float64 >>> s1 = Series({'a': 0.1, 'b': 1.2, 'c': 2.3}) >>> s2 = Series({'a': 1.0, 'b': 2.0, 'c': 3.0}) >>> s1 + s2 a 1.1 b 3.2 c 5.3 dtype: float64