Skip to content

Commit

Permalink
Note on fitted values instead of means to treat AR components with y …
Browse files Browse the repository at this point in the history
…containing missings
  • Loading branch information
DomenicoPerrottaJRC committed Jan 11, 2025
1 parent 8283542 commit fc0d7d1
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion toolbox/regression/LTSts.m
Original file line number Diff line number Diff line change
Expand Up @@ -1301,8 +1301,10 @@
end
% A similar replacement has to be done for units in y that are missing.
% Here we take the mean of the non-missing values around the missings.
% To be chcked: can we use the fitted values instead?
% likyhat(beta0,yToUseforLagged)
yToUseforLagged = fillNaNWithAdjacentMean(yToUseforLagged);

for j=1:lARp
selj=ARp(j);
Ylagged(:,j)=[yToUseforLagged(1:selj); yToUseforLagged(1:end-selj)];
Expand Down

0 comments on commit fc0d7d1

Please sign in to comment.