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: spm_read_netcdf.m
    path of file: ./repos/spm
    
    the code of the file until where you have to start completion: function cdf = spm_read_netcdf(fname)

    
function cdf = spm_read_netcdf(fname)
% Read the header information from a NetCDF file into a data structure
% FORMAT cdf = spm_read_netcdf(fname)
% fname - name of NetCDF file
% cdf   - data structure
%
% See: http://www.unidata.ucar.edu/packages/netcdf/
%__________________________________________________________________________

% John Ashburner
% Copyright (C) 1999-2022 Wellcome Centre for Human Neuroimaging


dsiz     = [1 1 2 4 4 8];
fp=fopen(fname,'r','ieee-be');
if fp==-1
    cdf = [];
    return;
end