You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: okid.m
    path of file: ./repos/MataveID/old/source
    
    the code of the file until where you have to start completion: % Observer Kalman Filter Identification
% Input: u(input signal), y(output signal), sampleTime, delay(optional), regularization(optional), systemorder(optional)
% Output: sysd(Discrete state space model), K(Kalman gain matr
    
function will find markov parameters Yk and Yo from Ybar1 and Ybar2
% In this example, we indexing from 1, not 0.
function [Yk, Yo] = getMarkov(Ybar1, Ybar2, D, p)
  Yk = zeros(1, p);
  Yo = zeros(1, p);
  for k = 1:p
    
    % Find the Ybar1 and Ybar2
    Ybar1_k = Ybar1(k);
    Ybar2_k = Ybar2(k);
    
    % Sum
    Ysum = 0;
    Yosum = 0;
    for i = 1:k-1
      Ysum = Ysum + Ybar2(i)*Yk(k-i);
      Yosum = Yosum + Ybar2(i)*Yo(k-i);
    end