{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "## Enrich Points from a Dataset\n", "\n", "This example illustrates how to enrich points that are in a dataset with variables from CARTO's Data Observatory.\n", "\n", "_Note: You'll need [CARTO Account](https://carto.com/signup) credentials to reproduce this example._" ] }, { "cell_type": "code", "execution_count": 1, "metadata": {}, "outputs": [], "source": [ "from cartoframes.auth import set_default_credentials\n", "\n", "set_default_credentials('creds.json')" ] }, { "cell_type": "code", "execution_count": 2, "metadata": {}, "outputs": [ { "data": { "text/html": [ "
\n", "\n", "\n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", "
num_bike_dropoffsnum_bike_pickupstotal_eventsstation_idlongitudelatitudegeometry
017820438231000-77.05314438.858726POINT (-77.05314 38.85873)
122227649831001-77.05373838.857216POINT (-77.05374 38.85722)
2839710154931002-77.04921838.856372POINT (-77.04922 38.85637)
348748997631003-77.04961438.860167POINT (-77.04961 38.86017)
423022745731004-77.05955238.857937POINT (-77.05955 38.85794)
5661659132031005-77.05993038.862077POINT (-77.05993 38.86208)
644843688431006-77.06339838.863298POINT (-77.06340 38.86330)
711461521266731007-77.05112938.857474POINT (-77.05113 38.85747)
832931164031009-77.05151338.848455POINT (-77.05151 38.84846)
939637376931010-77.05031538.842644POINT (-77.05031 38.84264)
\n", "
" ], "text/plain": [ " num_bike_dropoffs num_bike_pickups total_events station_id longitude \\\n", "0 178 204 382 31000 -77.053144 \n", "1 222 276 498 31001 -77.053738 \n", "2 839 710 1549 31002 -77.049218 \n", "3 487 489 976 31003 -77.049614 \n", "4 230 227 457 31004 -77.059552 \n", "5 661 659 1320 31005 -77.059930 \n", "6 448 436 884 31006 -77.063398 \n", "7 1146 1521 2667 31007 -77.051129 \n", "8 329 311 640 31009 -77.051513 \n", "9 396 373 769 31010 -77.050315 \n", "\n", " latitude geometry \n", "0 38.858726 POINT (-77.05314 38.85873) \n", "1 38.857216 POINT (-77.05374 38.85722) \n", "2 38.856372 POINT (-77.04922 38.85637) \n", "3 38.860167 POINT (-77.04961 38.86017) \n", "4 38.857937 POINT (-77.05955 38.85794) \n", "5 38.862077 POINT (-77.05993 38.86208) \n", "6 38.863298 POINT (-77.06340 38.86330) \n", "7 38.857474 POINT (-77.05113 38.85747) \n", "8 38.848455 POINT (-77.05151 38.84846) \n", "9 38.842644 POINT (-77.05031 38.84264) " ] }, "execution_count": 2, "metadata": {}, "output_type": "execute_result" } ], "source": [ "from geopandas import read_file\n", "\n", "arlington_file = 'http://libs.cartocdn.com/cartoframes/files/bikes.geojson'\n", "bikeshare_gdf = read_file(arlington_file)\n", "bikeshare_gdf.head(10)" ] }, { "cell_type": "code", "execution_count": 3, "metadata": {}, "outputs": [ { "data": { "text/plain": [ "[ #'US Census Block Groups Geoids',\n", " #'First day of the year the survey was issued',\n", " #'Total Population. The total number of all people l...',\n", " #'Households. A count of the number of households in...',\n", " #'Male Population. The number of people within each ...',\n", " #'Female Population. The number of people within eac...',\n", " #'Median Age. The median age of all people in a give...',\n", " #'Male under 5 years. The male population over the a...',\n", " #'Male age 5 to 9. The male population between the a...',\n", " #'Male age 10 to 14. The male population between the...',\n", " #'Male age 15 to 17. The male population between the...',\n", " #'Male age 18 and 19. The male population between th...',\n", " #'Male age 20. The male population with an age of tw...',\n", " #'Male age 21. The male population with an age of tw...',\n", " #'Male age 22 to 24. The male population between the...',\n", " #'Male age 25 to 29. The male population between the...',\n", " #'Male age 30 to 34. The male population between the...',\n", " #'Male age 35 to 39. The male population between the...',\n", " #'Male age 40 to 44. The male population between the...',\n", " #'Men age 45 to 49. The male population between the ...',\n", " #'Men age 50 to 54. The male population between the ...',\n", " #'Men age 55 to 59. The male population between the ...',\n", " #'Men age 60 to 61. The male population between the ...',\n", " #'Men age 62 to 64. The male population between the ...',\n", " #'Male age 65 to 66. The male population between the...',\n", " #'Male age 67 to 69. The male population between the...',\n", " #'Male age 70 to 74. The male population between the...',\n", " #'Male age 75 to 79. The male population between the...',\n", " #'Male age 80 to 84. The male population between the...',\n", " #'Male age 85 and over. The male population of the a...',\n", " #'Female under 5 years. The female population over t...',\n", " #'Female age 5 to 9. The female population between t...',\n", " #'Female age 10 to 14. The female population between...',\n", " #'Female age 15 to 17. The female population between...',\n", " #'Female age 18 and 19. The female population betwee...',\n", " #'Female age 20. The female population with an age o...',\n", " #'Female age 21. The female population with an age o...',\n", " #'Female age 22 to 24. The female population between...',\n", " #'Female age 25 to 29. The female population between...',\n", " #'Female age 30 to 34. The female population between...',\n", " #'Female age 35 to 39. The female population between...',\n", " #'Female age 40 to 44. The female population between...',\n", " #'Female age 45 to 49. The female population between...',\n", " #'Female age 50 to 54. The female population between...',\n", " #'Female age 55 to 59. The female population between...',\n", " #'Female age 60 and 61. The female population betwee...',\n", " #'Female age 62 to 64. The female population between...',\n", " #'Female age 65 to 66. The female population between...',\n", " #'Female age 67 to 69. The female population between...',\n", " #'Female age 70 to 74. The female population between...',\n", " #'Female age 75 to 79. The female population between...',\n", " #'Female age 80 to 84. The female population between...',\n", " #'Female age 85 and over. The female population of t...',\n", " #'White Population. The number of people identifying...',\n", " #'Population 1 year and over. All people, male and f...',\n", " #'Population 3 Years and Over. The total number of p...',\n", " #'Population 5 Years and Over. The number of people ...',\n", " #'Population 15 Years and Over. The number of people...',\n", " #'Population age 16 and over. The number of people i...',\n", " #'Population 25 Years and Over. The number of people...',\n", " #'Population age 25 to 64. The number of people in e...',\n", " #'Never Married. The number of people in a geographi...',\n", " #'Currently married. The number of people in a geogr...',\n", " #'Married but separated. The number of people in a g...',\n", " #'Widowed. The number of people in a geographic area...',\n", " #'Divorced. The number of people in a geographic are...',\n", " #'Not a U.S. Citizen Population. The number of peopl...',\n", " #'Black or African American Population. The number o...',\n", " #'Asian Population. The number of people identifying...',\n", " #'Hispanic Population. The number of people identify...',\n", " #'American Indian and Alaska Native Population. The ...',\n", " #'Other Race population. The number of people identi...',\n", " #'Two or more races population. The number of people...',\n", " #'White including Hispanic',\n", " #'Black including Hispanic',\n", " #'Asian including Hispanic',\n", " #'American Indian and Alaska Native Population, incl...',\n", " #'Hispanic of any race',\n", " #'Population not Hispanic. The number of people not ...',\n", " #'Asian Men age 45 to 54',\n", " #'Asian Men age 55 to 64',\n", " #'Black Men age 45 to 54',\n", " #'Black Men age 55 to 64',\n", " #'Hispanic Men age 45 to 54',\n", " #'Hispanic Men age 55 to 64',\n", " #'White Men age 45 to 54',\n", " #'White Men age 55 to 64',\n", " #'Median Household Income in the past 12 Months. Wit...',\n", " #'Per Capita Income in the past 12 Months. Per capit...',\n", " #'Households with income less than $10,000. The numb...',\n", " #'Households with income of $10,000 to $14,999. The ...',\n", " #'Households with income of $15,000 to $19,999. The ...',\n", " #'Households with income of $20,000 to $24,999. The ...',\n", " #'Households with income of $25,000 to $29,999. The ...',\n", " #'Households with income of $30,000 to $34,999. The ...',\n", " #'Households with income of $35,000 to $39,999. The ...',\n", " #'Households with income of $40,000 to $44,999. The ...',\n", " #'Households with income of $45,000 to $49,999. The ...',\n", " #'Households with income of $50,000 to $59,999. The ...',\n", " #'Households with income of $60,000 to $74,999. The ...',\n", " #'Households with income of $75,000 to $99,999. The ...',\n", " #'Households with income of $100,000 to $124,999. Th...',\n", " #'Households with income of $125,000 to $149,999. Th...',\n", " #'Households with income of $150,000 to $199,999. Th...',\n", " #'Households with income of $200,000 Or More. The nu...',\n", " #'Households receiving retirement income',\n", " #'Population for Whom Poverty Status Determined. The...',\n", " #'Income In The Past 12 Months Below Poverty Level. ...',\n", " #'Gini Index. The Gini index, or index of income con...',\n", " #'Housing Units. A count of housing units in each ge...',\n", " #'Renter-Occupied Housing Units Paying Cash Rent Med...',\n", " #'Owner-Occupied Housing Units Lower Value Quartile',\n", " #'Owner-Occupied Housing Units Median Value. The mid...',\n", " #'Owner-Occupied Housing Units Upper Value Quartile',\n", " #'Occupied housing units. A housing unit is classifi...',\n", " #'Renter occupied housing units. All occupied units ...',\n", " #'Vacant Housing Units. The count of vacant housing ...',\n", " #'Vacant Housing Units for Rent. The count of vacant...',\n", " #'Vacant Housing Units for Sale. The count of vacant...',\n", " #'Single-family (one unit) detached dwellings. This ...',\n", " #'Single-family (one unit) attached dwellings. This ...',\n", " #'Two-family (two unit) dwellings',\n", " #'Multifamily dwellings with three to 4 units',\n", " #'Apartment buildings with 5 to 9 units',\n", " #'Apartment buildings with 10 to 19 units',\n", " #'Apartment buildings with 20 to 49 units',\n", " #'Apartment buildings with 50 or more units',\n", " #'Mobile homes. A manufactured home is defined as a ...',\n", " #'Housing units built in 2005 or later. A house, an ...',\n", " #'Housing units built between 2000 and 2004. A house...',\n", " #'Housing units built before 1939. A house, an apart...',\n", " #'Median Year Structure Built. Median Year Structure...',\n", " #'Married households. People in formal marriages, as...',\n", " #'Nonfamily Households. A householder living alone o...',\n", " #'Family Households. A family consists of a househol...',\n", " #'Households on cash public assistance or receiving ...',\n", " #'Households with two male partners. An unmarried pa...',\n", " #'Households with two female partners. An unmarried ...',\n", " #'Children under 18 Years of Age. The number of peop...',\n", " #'Children under 18 years of age in single female-le...',\n", " #'Median Rent. The median contract rent within a geo...',\n", " #'Percent of Household Income Spent on Rent. Within ...',\n", " #'Housing units without rent burden computed. Units ...',\n", " #'Housing units spending over 50% income on rent. Gr...',\n", " #'Housing units spending 40 to 49.9% income on rent....',\n", " #'Housing units spending 35 to 39.9% income on rent....',\n", " #'Housing units spending 30 to 34.9% income on rent....',\n", " #'Housing units spending 25 to 29.9% income on rent....',\n", " #'Housing units spending 20 to 24.9% income on rent....',\n", " #'Housing units spending 15 to 19.9% income on rent....',\n", " #'Housing units spending 10 to 14.9% income on rent....',\n", " #'Housing units spending less than 10% on rent. Gros...',\n", " #'Owner-occupied Housing Units',\n", " #'Owner-occupied Housing Units valued at $1,000,000 ...',\n", " #'Owner-occupied Housing Units with a Mortgage. The ...',\n", " #'Lived in a different house one year ago in a diffe...',\n", " #'Lived in a different house one year ago in the sam...',\n", " #'Families with young children (under 6 years of age...',\n", " #'Two-parent families with young children (under 6 y...',\n", " #'Two-parent families, both parents in labor force w...',\n", " #'Two-parent families, father only in labor force wi...',\n", " #'Two-parent families, mother only in labor force wi...',\n", " #'Two-parent families, neither parent in labor force...',\n", " #'One-parent families with young children (under 6 y...',\n", " #'One-parent families, father, with young children (...',\n", " #'One-parent families, father in labor force, with y...',\n", " #'Number of workers with a commute between 5 and 9 m...',\n", " #'Number of workers with less than 10 minute commute...',\n", " #'Number of workers with a commute between 10 and 14...',\n", " #'Number of workers with a commute between 15 and 19...',\n", " #'Number of workers with a commute between 20 and 24...',\n", " #'Number of workers with a commute between 25 and 29...',\n", " #'Number of workers with a commute between 30 and 34...',\n", " #'Number of workers with a commute between 35 and 39...',\n", " #'Number of workers with a commute between 40 and 44...',\n", " #'Number of workers with a commute between 35 and 44...',\n", " #'Number of workers with a commute between 45 and 59...',\n", " #'Number of workers with a commute of over 60 minute...',\n", " #'Number of workers with a commute between 60 and 89...',\n", " #'Number of workers with a commute of over 90 minute...',\n", " #'Workers age 16 and over who do not work from home....',\n", " #'Walked to Work. The number of workers age 16 years...',\n", " #'Worked at Home. The count within a geographical ar...',\n", " #'Workers age 16 and over with no vehicle. All peopl...',\n", " #'Car-free households. The number of households with...',\n", " #'One car households. The number of households with ...',\n", " #'Two car households. The number of households with ...',\n", " #'Three car households. The number of households wit...',\n", " #'Four car households. The number of households with...',\n", " #'Aggregate travel time to work. The total number of...',\n", " #'Commuters by Public Transportation. The number of ...',\n", " #'Commuters by Bus. The number of workers age 16 yea...',\n", " #'Commuters by Car, Truck, or Van. The number of wor...',\n", " #'Commuters by Carpool. The number of workers age 16...',\n", " #'Commuters by Subway or Elevated. The number of wor...',\n", " #'Commuters who drove alone. The number of workers a...',\n", " #'Population living in group quarters',\n", " #'Population Completed Associate's Degree. The numbe...',\n", " #'Population Completed Bachelor's Degree. The number...',\n", " #'Population Completed High School. The number of pe...',\n", " #'Population completed less than one year of college...',\n", " #'Population Completed Master's Degree. The number o...',\n", " #'Population completed more than one year of college...',\n", " #'Less than high school graduate. The number of peop...',\n", " #'Population with high school degree, including GED....',\n", " #'Population who completed a bachelor's degree. From...',\n", " #'Population with Bachelors Degree or Higher, Ages 2...',\n", " #'Population who completed a graduate or professiona...',\n", " #'Population who completed some college or obtained ...',\n", " #'Men age 45 to 64 who obtained an associate's degre...',\n", " #'Men age 45 to 64 who obtained a bachelor's degree',\n", " #'Men age 45 to 64 who obtained a graduate or profes...',\n", " #'Men age 45 to 64 who attained less than a 9th grad...',\n", " #'Men age 45 to 64 who attained between 9th and 12th...',\n", " #'Men age 45 to 64 who completed high school or obta...',\n", " #'Men age 45 to 64 who completed some college, no de...',\n", " #'Men age 45 to 64 (\"middle aged\"). The male populat...',\n", " #'Employed Population. The number of civilians 16 ye...',\n", " #'Unemployed Population',\n", " #'Population in Labor Force. The number of people in...',\n", " #'Population Not in Labor Force. The number of peopl...',\n", " #'Workers over the Age of 16. The number of people i...',\n", " #'Population in Armed Forces. The number of people i...',\n", " #'Population in Civilian Labor Force. The number of ...',\n", " #'Workers employed in firms in agriculture, forestry...',\n", " #'Workers employed in firms in arts, entertainment, ...',\n", " #'Workers employed in firms in construction. The Con...',\n", " #'Workers employed in firms in educational services,...',\n", " #'Workers employed in firms in finance, insurance, r...',\n", " #'Workers employed in firms in information. The Info...',\n", " #'Workers employed in firms in manufacturing. The Ma...',\n", " #'Workers employed in firms in other services except...',\n", " #'Workers employed in firms in public administration...',\n", " #'Workers employed in firms in retail trade. The Ret...',\n", " #'Workers employed in firms in professional scientif...',\n", " #'Workers employed in firms in transportation, wareh...',\n", " #'Workers employed in firms in wholesale trade. The ...',\n", " #'Workers employed in management business science an...',\n", " #'Workers employed in natural resources, constructio...',\n", " #'Workers employed in production, transportation, an...',\n", " #'Workers employed in sales and office occupations',\n", " #'Workers employed in service occupations',\n", " #'Civilian Employed Population in Management, Busine...',\n", " #'Civilian Employed Population in Sales and Office O...',\n", " #'Students Enrolled in Grades 1 to 4. The total numb...',\n", " #'Students Enrolled in Grades 5 to 8. The total numb...',\n", " #'Students Enrolled in Grades 9 to 12. The total num...',\n", " #'Students Enrolled in School. The total number of p...',\n", " #'Students Enrolled as Undergraduate in College. The...',\n", " #'Speaks only English at Home. The number of people ...',\n", " #'Speaks Spanish at Home. The number of people in a ...',\n", " #'Speaks Spanish at Home, speaks English less than \"...']" ] }, "execution_count": 3, "metadata": {}, "output_type": "execute_result" } ], "source": [ "from cartoframes.data.observatory import Dataset, Catalog\n", "\n", "dataset = Dataset.get('carto-do-public-data.usa_acs.demographics_sociodemographics_usa_censustract_2015_5yrs_20132017')\n", "dataset.variables" ] }, { "cell_type": "code", "execution_count": 4, "metadata": {}, "outputs": [ { "data": { "text/plain": [ " #'Car-free households. The number of households with...'" ] }, "execution_count": 4, "metadata": {}, "output_type": "execute_result" } ], "source": [ "from cartoframes.data.observatory import Variable\n", "\n", "variable = Variable.get('no_cars_ded903e2')\n", "variable" ] }, { "cell_type": "code", "execution_count": 5, "metadata": {}, "outputs": [], "source": [ "from cartoframes.data.observatory import Enrichment\n", "\n", "enrichment = Enrichment()\n", "\n", "enriched_dataset_gdf = enrichment.enrich_points(\n", " bikeshare_gdf,\n", " variables=[variable]\n", ")" ] }, { "cell_type": "code", "execution_count": 6, "metadata": {}, "outputs": [ { "data": { "text/html": [ "
\n", "\n", "\n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", "
num_bike_dropoffsnum_bike_pickupstotal_eventsstation_idlongitudelatitudegeometryno_carsdo_area
017820438231000-77.05314438.858726POINT (-77.05314 38.85873)567.02.007639e+05
122227649831001-77.05373838.857216POINT (-77.05374 38.85722)187.01.627917e+05
2839710154931002-77.04921838.856372POINT (-77.04922 38.85637)629.01.160783e+06
348748997631003-77.04961438.860167POINT (-77.04961 38.86017)629.01.160783e+06
423022745731004-77.05955238.857937POINT (-77.05955 38.85794)628.06.686098e+05
5661659132031005-77.05993038.862077POINT (-77.05993 38.86208)628.06.686098e+05
644843688431006-77.06339838.863298POINT (-77.06340 38.86330)628.06.686098e+05
711461521266731007-77.05112938.857474POINT (-77.05113 38.85747)629.01.160783e+06
832931164031009-77.05151338.848455POINT (-77.05151 38.84846)629.01.160783e+06
939637376931010-77.05031538.842644POINT (-77.05031 38.84264)629.01.160783e+06
\n", "
" ], "text/plain": [ " num_bike_dropoffs num_bike_pickups total_events station_id longitude \\\n", "0 178 204 382 31000 -77.053144 \n", "1 222 276 498 31001 -77.053738 \n", "2 839 710 1549 31002 -77.049218 \n", "3 487 489 976 31003 -77.049614 \n", "4 230 227 457 31004 -77.059552 \n", "5 661 659 1320 31005 -77.059930 \n", "6 448 436 884 31006 -77.063398 \n", "7 1146 1521 2667 31007 -77.051129 \n", "8 329 311 640 31009 -77.051513 \n", "9 396 373 769 31010 -77.050315 \n", "\n", " latitude geometry no_cars do_area \n", "0 38.858726 POINT (-77.05314 38.85873) 567.0 2.007639e+05 \n", "1 38.857216 POINT (-77.05374 38.85722) 187.0 1.627917e+05 \n", "2 38.856372 POINT (-77.04922 38.85637) 629.0 1.160783e+06 \n", "3 38.860167 POINT (-77.04961 38.86017) 629.0 1.160783e+06 \n", "4 38.857937 POINT (-77.05955 38.85794) 628.0 6.686098e+05 \n", "5 38.862077 POINT (-77.05993 38.86208) 628.0 6.686098e+05 \n", "6 38.863298 POINT (-77.06340 38.86330) 628.0 6.686098e+05 \n", "7 38.857474 POINT (-77.05113 38.85747) 629.0 1.160783e+06 \n", "8 38.848455 POINT (-77.05151 38.84846) 629.0 1.160783e+06 \n", "9 38.842644 POINT (-77.05031 38.84264) 629.0 1.160783e+06 " ] }, "execution_count": 6, "metadata": {}, "output_type": "execute_result" } ], "source": [ "enriched_dataset_gdf.head(10)" ] }, { "cell_type": "code", "execution_count": 7, "metadata": {}, "outputs": [ { "data": { "text/html": [ "\n", "\n", "\n", " None\n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", "\n", " \n", " \n", " \n", " \n", " \n", " \n", "\n", " \n", "\n", " \n", "\n", " \n", " \n", " \n", " \n", " \n", "\n", " \n", " \n", " \n", " \n", " \n", " \n", "\n", "\n", "\n", " Static map image\n", " \n", " \n", "
\n", "
\n", "
\n", " \n", " \n", "
\n", "
\n", " \n", "\n", "
\n", " \n", " \n", " \n", " \n", " \n", "
\n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", "
\n", " \n", " \n", "
\n", "
\n", "
\n", "
\n", " \n", "
\n", "
\n", "
\n", "\n", " \n", "\n", "
\n", "
\n", " :\n", "
\n", " \n", " \n", "
\n", "
\n", "\n", "
\n", " StackTrace\n", "
    \n", "
    \n", "
    \n", "\n", "\n", "\n", "\n", "\n", "\">\n", "\n", "" ], "text/plain": [ "" ] }, "execution_count": 7, "metadata": {}, "output_type": "execute_result" } ], "source": [ "from cartoframes.viz import Layer, size_continuous_style\n", "\n", "Layer(enriched_dataset_gdf, size_continuous_style('no_cars'))" ] } ], "metadata": { "kernelspec": { "display_name": "Python 3", "language": "python", "name": "python3" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.6.7" } }, "nbformat": 4, "nbformat_minor": 2 }