Wang Tao Wang Tao - 1 year ago 83
Python Question

How to set the label Fonts as "Time New Roman" by drawparallels in python

I have draw a map with latitudes labelled but I want to set the fonts as "Times New Roman". How to make it possible?


Answer Source

You need to set font family using pyplot of matplotlib.

import matplotlib.pyplot as plt
csfont = {'fontname':'Times New Roman'}
// write your code related to basemap here

You can also use the following to change font globally.

import matplotlib.pyplot as plt
plt.rcParams[""] = "Times New Roman"
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download