We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b166ed4 commit 410272fCopy full SHA for 410272f
1 file changed
src/SURD.cpp
@@ -189,6 +189,20 @@ Rcpp::List RcppSURD(const Rcpp::NumericMatrix& mat,
189
);
190
}
191
192
+ // Remove leading lagged NA (time series only)
193
+ if (nb.isNull() && nrows.isNull())
194
+ {
195
+ size_t lag_abs = static_cast<size_t>(std::abs(lag));
196
+
197
+ if (lag_abs > 0 && lag_abs < n_obs)
198
199
+ for (auto& vec : pm)
200
201
+ vec.erase(vec.begin(), vec.begin() + lag_abs);
202
+ }
203
204
205
206
infoxtr::surd::SURDRes res = infoxtr::surd::surd(
207
pm,
208
static_cast<size_t>(std::abs(max_order)),
0 commit comments