code: def _diff_vector(x, lag):
      # compute the lag for a vector (not a matrix)
      n = x.shape[0]
      lag = min(
          n, lag
      )  # if lag > n, then we just want an empty array back
      return x[lag:n] - x[: n - lag]
  
file_path: pmdarima/pmdarima/utils/array.py
imports: from sklearn.utils import validation
  import numpy
  import pandas
  from ..compat import DTYPE
  from ._array import C_intgrt_vec
label_desc: Use image node_id 5 for calling a global function with example usage: _diff_vector(x, lag) and returns: unknown