In order to create a netCDF-4 file using the classic model format, you should have MATLAB version R2010b.
nc_create_empty('test.nc','netcdf4-classic') nc_dump ( 'test.nc' )
netCDF-4 test.nc { }