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: np_readmarker.m
    path of file: ./repos/malini/Codes/deconvolution - model/spm8/external/fieldtrip/fileio/private
    
    the code of the file until where you have to start completion: function [np_marker] = np_readmarker (filename, idx_begin, data_length, option)
%
% function [np_marker] = np_readmarker (filename, idx_begin, data_length, option)
%
% np_readmarker reads marker from a NEURO PRAX marker file (*.EE_).
%
% Syntax:
%
%   [np_marker] = np_readdata(filename,idx_begin,data_length,'samples');
%   [np_marker] = np_readdata(filename,idx_begin,data_length,'time');
%
% Input data:
%
%   filename    -   the complete filename with path
%                   (e. g.  C:\Document...\20030716103637.EEG)
%   idx_begin   -   the start index of the data block to be read
%   data_length -   the length of the data block to be read
%   option      -   if option = 'samples':
%                       marker will be read from sample index 'idx_begin'
%                       to sample index 'idx_begin' + 'data_length' - 1
%                   if option = 'time':
%                       marker will be read from time index 'idx_begin'
%                       to time index 'idx_begin' + 'data_length'
%
%                   To read all markers use: idx_start = 0, data_length = inf, option =
%                   'samples'.
%
% Output data:
%
%   np_marker        -   structure
%
%      np_marker.markernames   -   cell array with markernames 
%      np_marker.markertyp     -   vector array with markertypes
%      np_marker.marker        -   cell array with marker vectors 
%                                  ( = sample indices if option = 'samples',
%                                    = time indices if option = 'time');
%
% Version:  1.2. (2005-01-19)
%           1.1. (2004-10-22)
%
% 1. Artefact trials will not be considered.
% 2. Trials within pause intervals will not be considered.
%
% See also: np_readfileinfo, np_readdata
%
% eldith GmbH
% Gustav-Kirchhoff-Str. 5
% D-98693 Ilmenau
% Germany
% 22.10.2004


% Dateiinfo's lesen
np_info=np_readfileinfo(filename,'NO_MINMAX');

    
function [np_marker] = np_readmarker (filename, idx_begin, data_length, option)
%
% function [np_marker] = np_readmarker (filename, idx_begin, data_length, option)
%
% np_readmarker reads marker from a NEURO PRAX marker file (*.EE_).
%
% Syntax:
%
%   [np_marker] = np_readdata(filename,idx_begin,data_length,'samples');
%   [np_marker] = np_readdata(filename,idx_begin,data_length,'time');
%
% Input data:
%
%   filename    -   the complete filename with path
%                   (e. g.  C:\Document...\20030716103637.EEG)
%   idx_begin   -   the start index of the data block to be read
%   data_length -   the length of the data block to be read
%   option      -   if option = 'samples':
%                       marker will be read from sample index 'idx_begin'
%                       to sample index 'idx_begin' + 'data_length' - 1
%                   if option = 'time':
%                       marker will be read from time index 'idx_begin'
%                       to time index 'idx_begin' + 'data_length'
%
%                   To read all markers use: idx_start = 0, data_length = inf, option =
%                   'samples'.
%
% Output data:
%
%   np_marker        -   structure
%
%      np_marker.markernames   -   cell array with markernames 
%      np_marker.markertyp     -   vector array with markertypes
%      np_marker.marker        -   cell array with marker vectors 
%                                  ( = sample indices if option = 'samples',
%                                    = time indices if option = 'time');
%
% Version:  1.2. (2005-01-19)
%           1.1. (2004-10-22)
%
% 1. Artefact trials will not be considered.
% 2. Trials within pause intervals will not be considered.
%
% See also: np_readfileinfo, np_readdata
%
% eldith GmbH
% Gustav-Kirchhoff-Str. 5
% D-98693 Ilmenau
% Germany
% 22.10.2004


% Dateiinfo's lesen
np_info=np_readfileinfo(filename,'NO_MINMAX');

% Daten initialisieren, Start- und Stopsamples ermitteln
if (0==idx_begin) && (inf==data_length)
    N_start=0;
    N_stop = np_info.N - 1;                 
else
    switch upper(option)
        case 'SAMPLES', 
            N_start = idx_begin;
            N_stop  = N_start + data_length - 1;
        case 'TIME',
            N_start = round(idx_begin*np_info.fa);
            N_stop  = N_start + round(data_length*np_info.fa) - 1;
        otherwise,
            error ('Bad specification for ''option''');
    end