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: circ_samplecdf.m
    path of file: ./repos/Image-Harmonization-Dataset-iHarmony4/Xue et al/dependency/CircStat2011f
    
    the code of the file until where you have to start completion: function [phis, cdf, phiplot, cdfplot] = circ_samplecdf(thetas, resolution)

% [phis, cdf, phiplot, cdfplot] = circ_samplecdf(thetas, resolution)
%
%   Helper function for circ_kuipertest.
%   Evaluates CDF of sample in thetas.
% 
% Input: 
%   thetas      sample (in radians)
%   resolution  resolution at which the cdf is evaluated
%
% Output:
%   phis        angles at which CDF is evaluated
%   cdf         CDF values at these angles
%   phiplot     as phi, for plotting
%   cdfplot     as cdf, for plotting
% 
%
% Circular Statistics Toolbox for Matlab

% By Marc J. Velasco, 2009

    
function [phis, cdf, phiplot, cdfplot] = circ_samplecdf(thetas, resolution)

% [phis, cdf, phiplot, cdfplot] = circ_samplecdf(thetas, resolution)
%
%   Helper function for circ_kuipertest.
%   Evaluates CDF of sample in thetas.
% 
% Input: 
%   thetas      sample (in radians)
%   resolution  resolution at which the cdf is evaluated
%
% Output:
%   phis        angles at which CDF is evaluated
%   cdf         CDF values at these angles
%   phiplot     as phi, for plotting
%   cdfplot     as cdf, for plotting
% 
%
% Circular Statistics Toolbox for Matlab

% By Marc J. Velasco, 2009
% velasco@ccs.fau.edu

if nargin < 2
    resolution = 100;
end