|
6 | 6 | A = np.array |
7 | 7 |
|
8 | 8 | from mpl_toolkits.axisartist.grid_finder import ExtremeFinderSimple |
| 9 | +from __future__ import print_function |
9 | 10 |
|
10 | 11 | def select_step_degree(dv): |
11 | 12 |
|
@@ -433,38 +434,38 @@ def _adjust_extremes(self, lon_min, lon_max, lat_min, lat_max): |
433 | 434 | #print select_step360(20.5+21.2/3600., 20.5+33.3/3600., 5) |
434 | 435 |
|
435 | 436 | # test threshold factor |
436 | | - print select_step360(20.5+11.2/3600., 20.5+53.3/3600., 5, |
437 | | - threshold_factor=60) |
| 437 | + print(select_step360(20.5+11.2/3600., 20.5+53.3/3600., 5, |
| 438 | + threshold_factor=60)) |
438 | 439 |
|
439 | | - print select_step360(20.5+11.2/3600., 20.5+53.3/3600., 5, |
440 | | - threshold_factor=1) |
| 440 | + print(select_step360(20.5+11.2/3600., 20.5+53.3/3600., 5, |
| 441 | + threshold_factor=1)) |
441 | 442 |
|
442 | 443 | fmt = FormatterDMS() |
443 | 444 | #print fmt("left", 60, [0, -30, -60]) |
444 | | - print fmt("left", 600, [12301, 12302, 12303]) |
| 445 | + print(fmt("left", 600, [12301, 12302, 12303])) |
445 | 446 |
|
446 | | - print select_step360(20.5+21.2/3600., 20.5+21.4/3600., 5) |
447 | | - print fmt("left", 36000, [738210, 738215, 738220]) |
448 | | - print fmt("left", 360000, [7382120, 7382125, 7382130]) |
449 | | - print fmt("left", 1., [45, 46, 47]) |
450 | | - print fmt("left", 10., [452, 453, 454]) |
| 447 | + print(select_step360(20.5+21.2/3600., 20.5+21.4/3600., 5)) |
| 448 | + print(fmt("left", 36000, [738210, 738215, 738220])) |
| 449 | + print(fmt("left", 360000, [7382120, 7382125, 7382130])) |
| 450 | + print(fmt("left", 1., [45, 46, 47])) |
| 451 | + print(fmt("left", 10., [452, 453, 454])) |
451 | 452 |
|
452 | 453 | if 0: |
453 | | - print select_step360(20+21.2/60., 21+33.3/60., 5) |
454 | | - print select_step360(20.5+21.2/3600., 20.5+33.3/3600., 5) |
455 | | - print select_step360(20+21.2/60., 20+53.3/60., 5) |
| 454 | + print(select_step360(20+21.2/60., 21+33.3/60., 5)) |
| 455 | + print(select_step360(20.5+21.2/3600., 20.5+33.3/3600., 5)) |
| 456 | + print(select_step360(20+21.2/60., 20+53.3/60., 5)) |
456 | 457 |
|
457 | 458 | ### |
458 | 459 | levs, n, factor = select_step360(20.5+21.2/3600., 20.5+27.25/3600., 5) |
459 | 460 | levs = levs * 0.1 |
460 | 461 | fmt = FormatterDMS() |
461 | 462 | #print fmt("left", 60, [0, -30, -60]) |
462 | | - print fmt("left", factor, levs) |
| 463 | + print(fmt("left", factor, levs)) |
463 | 464 |
|
464 | 465 |
|
465 | | - print select_step(-180, 180, 10, hour=False) |
466 | | - print select_step(-12, 12, 10, hour=True) |
| 466 | + print(select_step(-180, 180, 10, hour=False)) |
| 467 | + print(select_step(-12, 12, 10, hour=True)) |
467 | 468 |
|
468 | 469 | fmt = FormatterDMS() |
469 | 470 | #print fmt("left", 60, [0, -30, -60]) |
470 | | - print fmt("left", 3600, [0, -30, -60]) |
| 471 | + print(fmt("left", 3600, [0, -30, -60])) |
0 commit comments