Modifying to suit netCDF4 module
Fixed bugs in calls of wx