transbigdata.plotscale

transbigdata.plotscale(ax, bounds, textcolor='k', textsize=8, compasssize=1, accuracy='auto', rect=[0.1, 0.1], unit='KM', style=1, **kwargs)

Add compass and scale for a map

Parameters:
  • bounds (List) – The drawing boundary of the base map, [lon1,lat1,lon2,lat2] (WGS84 coordinate system), where lon1 and lat1 are the coordinates of the lower left corner and lon2 and lat2 are the coordinates of the upper right corner

  • textsize (number) – size of the text

  • compasssize (number) – size of the compass

  • accuracy (number) – Length of scale bar (m)

  • unit (str) – ‘KM’,’km’,’M’,’m’, the scale units

  • style (number) – 1 or 2, the style of the scale

  • rect (List) – The approximate position of the scale bar in the figure, such as [0.9,0.9], is in the upper right corner