# Numpy version: 1.19.3
import math
import numpy as np
def sin_func(x):
return math.sin(x)
x = np.arange(0, 4*math.pi, step=math.pi/360)
vecfunc = np.vectorize(sin_func)
y = vecfunc(x)'Programming > Python' 카테고리의 다른 글
| [Pandas] DataFrame 더 많은 행과 열 출력하기 (0) | 2022.09.05 |
|---|---|
| [Python] 문자열 앞에 0을 채우는 방법(zfill, rjust) (0) | 2022.07.16 |
| [Pandas] DataFrame 기간별 데이터 산출하기 (0) | 2022.06.14 |
| [Pandas] DataFrame에서 특정 리스트에 해당하는 열 추출하기 (0) | 2022.06.14 |
| [Python] 파이썬에서 평균 구하는 방법 (0) | 2022.03.25 |