質問編集履歴
1
エラーを修正しました。
test
CHANGED
File without changes
|
test
CHANGED
@@ -76,13 +76,13 @@
|
|
76
76
|
|
77
77
|
# 描画
|
78
78
|
|
79
|
-
y_train_predict_std = model.predict((train_query_x)
|
79
|
+
y_train_predict_std = model.predict((train_query_x))
|
80
80
|
|
81
|
-
y_train_predict = pd.DataFrame(
|
81
|
+
y_train_predict = pd.DataFrame(scaler_y.inverse_transform(y_train_predict_std))
|
82
82
|
|
83
83
|
y_train_predict.columns = ["SALES_PREDICT"]
|
84
84
|
|
85
|
-
plotMin =
|
85
|
+
plotMin = train_query_y.min() - ( y_train.max() - y_train.min() ) * 0.1
|
86
86
|
|
87
87
|
plotMax = y_train.max() + ( y_train.max() - y_train.min() ) * 0.1
|
88
88
|
|
@@ -104,12 +104,32 @@
|
|
104
104
|
|
105
105
|
```python
|
106
106
|
|
107
|
-
|
107
|
+
-------------------------------------------------------
|
108
108
|
|
109
|
-
|
109
|
+
LinearRegression(copy_X=True, fit_intercept=True, n_jobs=None, normalize=False)
|
110
110
|
|
111
|
-
|
111
|
+
R2 SCORE: TRAIN:0.5284165822957549
|
112
112
|
|
113
|
+
-------------------------------------------------------
|
114
|
+
|
115
|
+
---------------------------------------------------------------------------
|
116
|
+
|
117
|
+
NameError Traceback (most recent call last)
|
118
|
+
|
119
|
+
<ipython-input-417-7134a9c14592> in <module>()
|
120
|
+
|
121
|
+
14 # 描画
|
122
|
+
|
123
|
+
15 y_train_predict_std = model.predict((train_query_x))
|
124
|
+
|
125
|
+
---> 16 y_train_predict = pd.DataFrame(scaler_y.inverse_transform(y_train_predict_std))
|
126
|
+
|
127
|
+
17 y_train_predict.columns = ["SALES_PREDICT"]
|
128
|
+
|
129
|
+
18 plotMin = train_query_y.min() - ( y_train.max() - y_train.min() ) * 0.1
|
130
|
+
|
131
|
+
|
132
|
+
|
113
|
-
|
133
|
+
NameError: name 'scaler_y' is not defined
|
114
134
|
|
115
135
|
```
|