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: plotConvergence.m
    path of file: ./repos/TOP-OPT-Plates/+plot
    
    the code of the file until where you have to start completion: function plotConvergence(iter, values, obj)

    
function plotConvergence(iter, values, obj)
% Plot convergence plots.
% 'iter' is a vector containing the number of iterations.
% 'values' is a vector containing the values to plot.
% 'obj' is a caracter representing the type of convergence plot.

switch obj
    case 'c'
        % plot convergence in terms of compliance
        figure(1);
        plot(iter, values);
        title('Convergence of the objective function: Compliance');
        xlabel('Iterations'); ylabel('Compliance');
        drawnow;
    case 'f'
        % plot convergence in terms of the lowest eigenfrequency
        figure(1);
        lines = plot(iter, values);
        lines(size(values, 1)-3).LineWidth = 2;
        names = '1°';
        for i=2:size(values, 1)
            names = strcat(names, sprintf(' %.f°', i));
        end