Continuing from "Play with Prophet", I tried to predict the transition of the Bitcoin price.
Datasets
――It seems that the recent trend is that it is on the rise. ――The weekly trend seems to be "buy on Tuesday and sell on Sunday".
It smells like dust, so I'll investigate it a little more.
--Training data: 2017-05-27 ~ 2017-08-31 --Verification data: 2017-09-01 ~ 2017-09-08
Let's check the performance with SMAPE [^ 1].
――The tendency of weekly changes just by changing the period a little. What is it? ??
y_true = forecast["y"].values
y_pred = forecast["yhat"].values
print "FORECAST SMAPE: %.3f" % smape(y_true, y_pred)
# FORECAST SMAPE: 4.238
y_true = forecast["y"].values
y_pred = forecast["yhat"].values
print "FORECAST SMAPE: %.3f" % smape(y_true, y_pred)
# FORECAST SMAPE: 4.197
A little better than the default
y_median = np.asarray([np.median(y_true)] * len(y_true))
print "MEDIAN SMAPE: %.3f" % smape(y_true, y_median)
# MEDIAN SMAPE: 2.922
I don't know the median value of future data, but I will give it as a guide. The performance is better when using the median, so it seems that the prediction needs to be improved.
--Predict Bitcoin price changes using Prophet --The weekly tendency seems unreliable as it changes with slight fluctuations over a period of time. --Is there any improvement by finding the optimum parameters for changepoint_prior_scale?
References
Recommended Posts