GMTInvalidInput: Unrecognized parameter 'fill' in fig.plot

Hi everybody. Plotting the first figure of the tutorial website https://www.pygmt.org/latest/tutorials/basics/plot.html#sphx-glr-tutorials-basics-plot-py

which is as simple as this:

import pygmt
data = pygmt.datasets.load_sample_data(name=“japan_quakes”)
region = [
data.longitude.min() - 1,
data.longitude.max() + 1,
data.latitude.min() - 1,
data.latitude.max() + 1,
]

print(region)
print(data.head())

fig = pygmt.Figure()
fig.basemap(region=region, projection=“M15c”, frame=True)
fig.coast(land=“black”, water=“skyblue”)
fig.plot(x=data.longitude, y=data.latitude, style=“c0.3c”, fill=“white”, pen=“black”)
fig.show()

I get this wired error: pygmt.exceptions.GMTInvalidInput: Unrecognized parameter ‘fill’.

Could you please help me how to fix this. Many thanks.

Hello @SoniaBazargan,

probably you are not using the latest PyGMT version, which is currently v0.9.0.
Together with release v0.8.0 the parameter color was renamed to fill (for consistency across the plotting methods, please see issue https://github.com/GenericMappingTools/pygmt/issues/1617). Thus, fill is available for versions v0.8.0 or higher. In case you are using an older version, you have to use color.

Thanks for your help :slight_smile: I appreciate it.