Describe the bug
The diagonal matrix for the WLSV method currently is computed by the code below under hts.functions.optimal_combination function:
elif method == MethodT.WLSV.name:
diag = [mse[key] for key in mse.keys()]
diag = np.diag(np.flip(np.hstack(diag) + 0.0000001, 0))
Is there a reason for the np.flip? I am assuming that the mse.keys() are in the same order as the forecasts parameter to hts.functions.optimal_combination function. By flipping the array, the base forecast errors will be presented in the diagonal matrix in a reverse order.
Describe the bug The diagonal matrix for the WLSV method currently is computed by the code below under
hts.functions.optimal_combination
function:Is there a reason for the
np.flip
? I am assuming that themse.keys()
are in the same order as theforecasts
parameter tohts.functions.optimal_combination
function. By flipping the array, the base forecast errors will be presented in the diagonal matrix in a reverse order.Example:
However, referring to the formula here, I am expecting diagonal matrix to be:
To Reproduce Steps to reproduce the behavior
Please see example above.
Expected behavior A clear and concise description of what you expected to happen.
Please see example above.
Desktop (please complete the following information):
Additional context Add any other context about the problem here.
Much appreciation for any clarification and your patience if I misunderstood something. Thank you for your great work here.