Is it possible to set figure axis_type in bokeh to geographical (long/lat)?

Viewed 242

I'm creating an application using python bokeh that plots points on a map. I have lat/long points, and I want to lay my points over the cartodbpositron tile.

All the examples that I've seen use the basic x_axis_type = "mercator" with x_range and y_range being mercator as well. I don't want to convert my long/lat coordinates to mercator using a formula as I don't want to lose the accuracy I need. Is there a way to set the x_y_range_type to geographical or something of that sort where it sets lat/long?


USA = x_range,y_range = ((-13884029,-7453304), (2698291,6455972))

p = figure(tools='pan, wheel_zoom', x_range=x_range, y_range=y_range,
           x_axis_type="mercator", y_axis_type="mercator")
tile_provider = get_provider(Vendors.CARTODBPOSITRON)
p.add_tile(tile_provider)

My longitude latitude points are in california, but when I run this code I'll get my points in the middle of the ocean since it's mercator values.

I appreciate any help to a solution.

0 Answers
Related