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: getrSample.m
    path of file: ./repos/GECKO/src/geckomat/kcat_sensitivity_analysis/Bayesian
    
    the code of the file until where you have to start completion: function r = getrSample(mu,sigma,step,method)
% getrSample
%   Samples random kcats from a distribution.
%
% Input:
%   mu              Mean of distribution (data is logged to get a normal distr)
%   sigma           Std deviation of the distribution

    
function r = getrSample(mu,sigma,step,method)
% getrSample
%   Samples random kcats from a distribution.
%
% Input:
%   mu              Mean of distribution (data is logged to get a normal distr)
%   sigma           Std deviation of the distribution
%   step            Number of kcats to sample
%   method          shape of distribution: 'normal' or 'uniform'. 
%                   (Optional, default is 'normal')
% Output:
%   r               The sampled kcats
%
if nargin < 4
    method = 'normal';
end