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: pop_micro_selectNmicro.m
    path of file: ./repos/Microstate-EEGlab-toolbox/Microstate1.0
    
    the code of the file until where you have to start completion: % [] = pop_micro_selectNmicro() - Select active number of microstates.
%
%  Select active number of microstates. By default this function will plot
%  a new figure with four measures of fit of the best segmentation for
%  each number of microstates.
%  The user can also directly define the active number of microstates
%  without plotting measu
    
function settings = interpret_popup(pop_out, settings, style, popmenu)
% Interpret output from pop_up window, "pop_out", and arrange it in
% "settings" struct. The fields in "style" should be the same as in "pop_out"
% (defined as tags in inputgui.m). The struct popmenu is optional and only
% needed if popmenus are used in the pop_up window.

names = fieldnames(style);
for i = 1:length(names)
    switch style.(names{i})
        case 'edit'
            if isempty(pop_out.(names{i})) % empty?
                settings.(names{i}) = [];
            else
                settings.(names{i}) = eval(pop_out.(names{i}));
            end