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: icatb_returnResizedImage.m
    path of file: ./repos/gift/GroupICAT/icatb/icatb_display_functions
    
    the code of the file until where you have to start completion: function [structuralImage, compImages, coords, HInfo, text_left_right] = icatb_returnResizedImage(structFile, compFiles, ...
    anatomicalPlane, slices_in_mm, dataType, complexInfo, file_numbers, mask_file)
% return the structural image and the reshaped component images
% if the data type is complex then return complex images
%
% Inputs:
% 1.
    
function inputIm = getValues_in_mask(inputIm, maskvec)
% sub function to get the voxel values in the mask only

% size of the input image
size_input = size(inputIm);


% apply this only if maskvec is not empty
if ~isempty(maskvec)
    % loop over number of components
    for ii = 1:size_input(1)
        tempIm = squeeze(inputIm(ii, :, :, :));
        tempIm = tempIm(:);
        % initialise temp vector
        temp = zeros(1, length(tempIm));
        temp(maskvec) = tempIm(maskvec);
        clear tempIm;
        % set the new image to the current component
        inputIm(ii, :, :, :) = reshape(temp, [size_input(2:end