fp1 = np.polyfit(data_result['인구수'], data_result['소계'], 1) f1 = np.poly1d(fp1) f1(400000)
1) 경향선을 그리기 위한 x 데이터 생성 2) a부터 b까지 n개의 등간격 데이터 생성