Hi all! I’m new to using pygmt and have ran into an issue trying to plot using pygmt.surface() using spacing in a format other than degrees. I am trying to plot the following gridded modeled data that has a 4km x 4km resolution:
To do this, I first use pygmt.blockmean(), using the data’s lon, lat, and NOx concentrations as my x,y, and z, and spacing= [‘4000e’,‘4000e’]. Then I use the blockmean output as ‘data’ in the pygmt.surface() function, along with my specified region, and the spacing defined as [‘4000e’,‘4000e’]. When doing this I receive the following error:
GMTCLibError: Module ‘surface’ failed with status code 79:
surface [ERROR]: Grid must have at least 4 nodes in each direction (you have 1 by 1) - abort.
I’ve tried changing the spacing to be a larger resolution (e.g, 16000e,16000e and 5.0k,5.0k) and smaller. I’ve also updated to the most recent version of pygmt. However, when I rerun the script using spacing in the unit degrees, the script works just fine. I believe the pygmt.surface() function is not registering that I am passing a spacing in meters opposed to degrees, and it results in this error. Is there any type of fix for this? Thank you in advance!