|
31 | 31 | }, |
32 | 32 | { |
33 | 33 | "cell_type": "code", |
34 | | - "execution_count": 1, |
| 34 | + "execution_count": 2, |
35 | 35 | "metadata": {}, |
36 | 36 | "outputs": [], |
37 | 37 | "source": [ |
|
464 | 464 | }, |
465 | 465 | { |
466 | 466 | "cell_type": "code", |
467 | | - "execution_count": null, |
| 467 | + "execution_count": 3, |
468 | 468 | "metadata": {}, |
469 | | - "outputs": [], |
| 469 | + "outputs": [ |
| 470 | + { |
| 471 | + "data": { |
| 472 | + "application/vnd.jupyter.widget-view+json": { |
| 473 | + "model_id": "a493358378c84d268008697bc7bc80a7", |
| 474 | + "version_major": 2, |
| 475 | + "version_minor": 0 |
| 476 | + }, |
| 477 | + "text/plain": [ |
| 478 | + "MapView(layout=Layout(height='400px', width='100%'), zoom=4.0)" |
| 479 | + ] |
| 480 | + }, |
| 481 | + "metadata": {}, |
| 482 | + "output_type": "display_data" |
| 483 | + }, |
| 484 | + { |
| 485 | + "data": { |
| 486 | + "text/html": [ |
| 487 | + "<div class=\"map-static-img-preview-1c18855c-dee5-4f2a-b1e7-4f616f4fa53f\"><img src=\"\"></img></div>" |
| 488 | + ], |
| 489 | + "text/plain": [ |
| 490 | + "<IPython.core.display.HTML object>" |
| 491 | + ] |
| 492 | + }, |
| 493 | + "metadata": {}, |
| 494 | + "output_type": "display_data" |
| 495 | + } |
| 496 | + ], |
470 | 497 | "source": [ |
471 | 498 | "# Log into to GIS as we will save the widget as a web map later\n", |
472 | 499 | "gis = GIS(\"https://www.arcgis.com\", \"arcgis_python\", \"P@ssword123\")\n", |
|
490 | 517 | }, |
491 | 518 | { |
492 | 519 | "cell_type": "code", |
493 | | - "execution_count": 17, |
| 520 | + "execution_count": 12, |
494 | 521 | "metadata": {}, |
495 | 522 | "outputs": [ |
496 | 523 | { |
|
505 | 532 | " <Item title:\"World Exclusive Economic Zone Boundaries\" type:Feature Layer Collection owner:esri>,\n", |
506 | 533 | " <Item title:\"Location Tracking\" type:Feature Layer Collection owner:esri>,\n", |
507 | 534 | " <Item title:\"USA Anchorage Areas (Mature Support)\" type:Feature Layer Collection owner:esri>,\n", |
508 | | - " <Item title:\"USA Soils Map Units\" type:Feature Layer Collection owner:esri>]" |
| 535 | + " <Item title:\"USA Territorial Sea Boundary (Mature Support)\" type:Feature Layer Collection owner:esri>]" |
509 | 536 | ] |
510 | 537 | }, |
511 | | - "execution_count": 17, |
| 538 | + "execution_count": 12, |
512 | 539 | "metadata": {}, |
513 | 540 | "output_type": "execute_result" |
514 | 541 | } |
|
532 | 559 | "metadata": {}, |
533 | 560 | "outputs": [], |
534 | 561 | "source": [ |
535 | | - "world_timezones_item = flayer_search_result[4]\n", |
| 562 | + "world_timezones_item = gis.content.get('312cebfea2624e108e234220b04460b8')\n", |
536 | 563 | "usa_map.add_layer(world_timezones_item)" |
537 | 564 | ] |
538 | 565 | }, |
|
546 | 573 | }, |
547 | 574 | { |
548 | 575 | "cell_type": "code", |
549 | | - "execution_count": 42, |
| 576 | + "execution_count": 10, |
550 | 577 | "metadata": {}, |
551 | 578 | "outputs": [ |
552 | 579 | { |
|
555 | 582 | "<FeatureLayer url:\"https://services.arcgis.com/P3ePLMYs2RVChkJx/arcgis/rest/services/World_Countries/FeatureServer/0\">" |
556 | 583 | ] |
557 | 584 | }, |
558 | | - "execution_count": 42, |
| 585 | + "execution_count": 10, |
559 | 586 | "metadata": {}, |
560 | 587 | "output_type": "execute_result" |
561 | 588 | } |
562 | 589 | ], |
563 | 590 | "source": [ |
564 | | - "world_countries_item = flayer_search_result[-1]\n", |
| 591 | + "world_countries_item = gis.content.get('ac80670eb213440ea5899bbf92a04998')\n", |
565 | 592 | "world_countries_layer = world_countries_item.layers[0]\n", |
566 | 593 | "world_countries_layer" |
567 | 594 | ] |
|
597 | 624 | "metadata": {}, |
598 | 625 | "outputs": [], |
599 | 626 | "source": [ |
600 | | - "freeway_feature_layer = flayer_search_result[-2].layers[0]\n", |
| 627 | + "freeway_feature_layer = gis.content.get('51275617f1274103b81d99cd0ad94a40').layers[0]\n", |
601 | 628 | "usa_map.add_layer(freeway_feature_layer, {\"renderer\":\"ClassedSizeRenderer\", \"field_name\": \"DIST_MILES\"})" |
602 | 629 | ] |
603 | 630 | }, |
|
0 commit comments