1
$\begingroup$

I'm going straight to the task; I start with the following list of Florida counties:

counties = Dataset[{<|"County" -> "ALACHUA"|>, <|"County" -> "BAKER"|>, <|
"County" -> "BAY"|>, <|"County" -> "BRADFORD"|>, <|
"County" -> "BREVARD"|>, <|"County" -> "BROWARD"|>, <|
"County" -> "CALHOUN"|>, <|"County" -> "CHARLOTTE"|>, <|
"County" -> "CITRUS"|>, <|"County" -> "CLAY"|>, <|
"County" -> "COLLIER"|>, <|"County" -> "COLUMBIA"|>, <|
"County" -> "DESOTO"|>, <|"County" -> "DIXIE"|>, <|
"County" -> "DUVAL"|>, <|"County" -> "ESCAMBIA"|>, <|
"County" -> "FLAGLER"|>, <|"County" -> "FRANKLIN"|>, <|
"County" -> "GADSDEN"|>, <|"County" -> "GILCHRIST"|>, <|
"County" -> "GLADES"|>, <|"County" -> "GULF"|>, <|
"County" -> "HAMILTON"|>, <|"County" -> "HARDEE"|>, <|
"County" -> "HENDRY"|>, <|"County" -> "HERNANDO"|>, <|
"County" -> "HIGHLANDS"|>, <|"County" -> "HILLBOUROUGH"|>, <|
"County" -> "HOLMES"|>, <|"County" -> "INDIANRIVER"|>, <|
"County" -> "JACKSON"|>, <|"County" -> "JEFFERSON"|>, <|
"County" -> "LAFAYETTE"|>, <|"County" -> "LAKE"|>, <|
"County" -> "LEE"|>, <|"County" -> "LEON"|>, <|
"County" -> "LEVY"|>, <|"County" -> "LIBERTY"|>, <|
"County" -> "MADISON"|>, <|"County" -> "MANATEE"|>, <|
"County" -> "MARION"|>, <|"County" -> "MARTIN"|>, <|
"County" -> "MIAMI-DADE"|>, <|"County" -> "MONROE"|>, <|
"County" -> "NASSAU"|>, <|"County" -> "OKALOOSA"|>, <|
"County" -> "OKEECHOBEE"|>, <|"County" -> "ORANGE"|>, <|
"County" -> "OSCEOLA"|>, <|"County" -> "PALMBEACH"|>, <|
"County" -> "PASCO"|>, <|"County" -> "PINELLAS"|>, <|
"County" -> "POLK"|>, <|"County" -> "PUTNAM"|>, <|
"County" -> "SANTAROSA"|>, <|"County" -> "SARASOTA"|>, <|
"County" -> "SEMINOLE"|>, <|"County" -> "SAINTJOHNS"|>, <|
"County" -> "SAINTLUCIE"|>, <|"County" -> "SUMTER"|>, <|
"County" -> "SUWANNEE"|>, <|"County" -> "TAYLOR"|>, <|
"County" -> "UNION"|>, <|"County" -> "VOLUSIA"|>, <|
"County" -> "WAKULLA"|>, <|"County" -> "WALTON"|>, <|
"County" -> "WASHINGTON"|>}]

Next; is a list of adjacent counties corresponding to each of the above 67 counties. For example : ALACHUA county have the following adjacent counties: BRADFORD, COLUMBIA, GILCHRIST, LEVY, MARION, PUTNAM and UNION.

adjacentcounties = 
 Dataset[{<|"County" -> "ALACHUA", 
    "AdjacentCounty" -> {"BRADFORD", "COLUMBIA", "GILCHRIST", "LEVY", 
      "MARION", "PUTNAM", "UNION"}|>, <|"County" -> "BAKER", 
    "AdjacentCounty" -> {"BRADFORD", "CLAY", "COLUMBIA", "DUVAL", 
      "NASSAU", "UNION"}|>, <|"County" -> "BAY", 
    "AdjacentCounty" -> {"CALHOUN", "GULF", "JACKSON", "WALTON", 
      "WASHINGTON"}|>, <|"County" -> "BRADFORD", 
    "AdjacentCounty" -> {"ALACHUA", "BAKER", "CLAY", "PUTNAM", 
      "UNION"}|>, <|"County" -> "BREVARD", 
    "AdjacentCounty" -> {"INDIANRIVER", "ORANGE", "OSCEOLA", 
      "SEMINOLE", "VOLUSIA"}|>, <|"County" -> "BROWARD", 
    "AdjacentCounty" -> {"COLLIER", "HENDRY", "MIAMI-DADE", 
      "PALMBEACH"}|>, <|"County" -> "CALHOUN", 
    "AdjacentCounty" -> {"BAY", "GADSDEN", "GULF", "JACKSON", 
      "LIBERTY"}|>, <|"County" -> "CHARLOTTE", 
    "AdjacentCounty" -> {"DESOTO", "GLADES", "HENDRY", "HIGHLANDS", 
      "LEE", "SARASOTA"}|>, <|"County" -> "CITRUS", 
    "AdjacentCounty" -> {"HERNANDO", "LEVY", "MARION", "SUMTER"}|>, <|
    "County" -> "CLAY", 
    "AdjacentCounty" -> {"BAKER", "BRADFORD", "DUVAL", "PUTNAM", 
      "SAINTJOHNS"}|>, <|"County" -> "COLLIER", 
    "AdjacentCounty" -> {"BROWARD", "HENDRY", "LEE", "MIAMI-DADE", 
      "MONROE"}|>, <|"County" -> "COLUMBIA", 
    "AdjacentCounty" -> {"ALACHUA", "BAKER", "GILCHRIST", "HAMILTON", 
      "SUWANNEE", "UNION"}|>, <|"County" -> "DESOTO", 
    "AdjacentCounty" -> {"CHARLOTTE", "GLADES", "HARDEE", "HIGHLANDS",
       "MANATEE", "SARASOTA"}|>, <|"County" -> "DIXIE", 
    "AdjacentCounty" -> {"GILCHRIST", "LAFAYETTE", "LEVY", 
      "TAYLOR"}|>, <|"County" -> "DUVAL", 
    "AdjacentCounty" -> {"BAKER", "CLAY", "NASSAU", "SAINTJOHNS"}|>, <|
    "County" -> "ESCAMBIA", "AdjacentCounty" -> {"SANTAROSA"}|>, <|
    "County" -> "FLAGLER", 
    "AdjacentCounty" -> {"PUTNAM", "SAINTJOHNS", "VOLUSIA"}|>, <|
    "County" -> "FRANKLIN", 
    "AdjacentCounty" -> {"GULF", "LIBERTY", "WAKULLA"}|>, <|
    "County" -> "GADSDEN", 
    "AdjacentCounty" -> {"CALHOUN", "JACKSON", "LEON", "LIBERTY"}|>, <|
    "County" -> "GILCHRIST", 
    "AdjacentCounty" -> {"ALACHUA", "COLUMBIA", "DIXIE", "LAFAYETTE", 
      "LEVY", "SUWANNEE"}|>, <|"County" -> "GLADES", 
    "AdjacentCounty" -> {"CHARLOTTE", "DESOTO", "HENDRY", "HIGHLANDS",
       "LEE", "MARTIN", "OKEECHOBEE", "PALMBEACH"}|>, <|
    "County" -> "GULF", 
    "AdjacentCounty" -> {"BAY", "CALHOUN", "FRANKLIN", "LIBERTY"}|>, <|
    "County" -> "HAMILTON", 
    "AdjacentCounty" -> {"COLUMBIA", "MADISON", "SUWANNEE"}|>, <|
    "County" -> "HARDEE", 
    "AdjacentCounty" -> {"DESOTO", "HIGHLANDS", "HILLSBOROUGH", 
      "MANATEE", "POLK"}|>, <|"County" -> "HENDRY", 
    "AdjacentCounty" -> {"BROWARD", "CHARLOTTE", "COLLIER", "GLADES", 
      "LEE", "MARTIN", "OKEECHOBEE", "PALMBEACH"}|>, <|
    "County" -> "HERNANDO", 
    "AdjacentCounty" -> {"CITRUS", "PASCO", "SUMTER"}|>, <|
    "County" -> "HIGHLANDS", 
    "AdjacentCounty" -> {"CHARLOTTE", "DESOTO", "GLADES", "HARDEE", 
      "OKEECHOBEE", "OSCEOLA", "POLK"}|>, <|
    "County" -> "HILLSBOROUGH", 
    "AdjacentCounty" -> {"HARDEE", "MANATEE", "PASCO", "PINELLAS", 
      "POLK"}|>, <|"County" -> "HOLMES", 
    "AdjacentCounty" -> {"JACKSON", "WALTON", "WASHINGTON"}|>, <|
    "County" -> "INDIANRIVER", 
    "AdjacentCounty" -> {"BREVARD", "OKEECHOBEE", "OSCEOLA", 
      "SAINTLUCIE"}|>, <|"County" -> "JACKSON", 
    "AdjacentCounty" -> {"BAY", "CALHOUN", "GADSDEN", "HOLMES", 
      "LIBERTY", "WASHINGTON"}|>, <|"County" -> "JEFFERSON", 
    "AdjacentCounty" -> {"LEON", "MADISON", "TAYLOR", "WAKULLA"}|>, <|
    "County" -> "LAFAYETTE", 
    "AdjacentCounty" -> {"DIXIE", "GILCHRIST", "MADISON", "SUWANNEE", 
      "TAYLOR"}|>, <|"County" -> "LAKE", 
    "AdjacentCounty" -> {"MARION", "ORANGE", "OSCEOLA", "POLK", 
      "SEMINOLE", "SUMTER", "VOLUSIA"}|>, <|"County" -> "LEE", 
    "AdjacentCounty" -> {"CHARLOTTE", "COLLIER", "GLADES", 
      "HENDRY"}|>, <|"County" -> "LEON", 
    "AdjacentCounty" -> {"GADSDEN", "JEFFERSON", "LIBERTY", 
      "WAKULLA"}|>, <|"County" -> "LEVY", 
    "AdjacentCounty" -> {"ALACHUA", "CITRUS", "DIXIE", "GILCHRIST", 
      "MARION"}|>, <|"County" -> "LIBERTY", 
    "AdjacentCounty" -> {"CALHOUN", "FRANKLIN", "GADSDEN", "GULF", 
      "JACKSON", "LEON", "WAKULLA"}|>, <|"County" -> "MADISON", 
    "AdjacentCounty" -> {"HAMILTON", "JEFFERSON", "LAFAYETTE", 
      "SUWANNEE", "TAYLOR"}|>, <|"County" -> "MANATEE", 
    "AdjacentCounty" -> {"DESOTO", "HARDEE", "HILLSBOROUGH", "POLK", 
      "SARASOTA"}|>, <|"County" -> "MARION", 
    "AdjacentCounty" -> {"ALACHUA", "CITRUS", "LAKE", "LEVY", 
      "PUTNAM", "SUMTER", "VOLUSIA"}|>, <|"County" -> "MARTIN", 
    "AdjacentCounty" -> {"GLADES", "HENDRY", "OKEECHOBEE", 
      "PALMBEACH", "SAINTLUCIE"}|>, <|"County" -> "MIAMI-DADE", 
    "AdjacentCounty" -> {"BROWARD", "COLLIER", "MONROE"}|>, <|
    "County" -> "MONROE", 
    "AdjacentCounty" -> {"COLLIER", "MIAMI-DADE"}|>, <|
    "County" -> "NASSAU", "AdjacentCounty" -> {"BAKER", "DUVAL"}|>, <|
    "County" -> "OKALOOSA", 
    "AdjacentCounty" -> {"SANTAROSA", "WALTON"}|>, <|
    "County" -> "OKEECHOBEE", 
    "AdjacentCounty" -> {"GLADES", "HENDRY", "HIGHLANDS", 
      "INDIANRIVER", "MARTIN", "OSCEOLA", "PALMBEACH", "POLK", 
      "SAINTLUCIE"}|>, <|"County" -> "ORANGE", 
    "AdjacentCounty" -> {"BREVARD", "LAKE", "OSCEOLA", "POLK", 
      "SEMINOLE", "VOLUSIA"}|>, <|"County" -> "OSCEOLA", 
    "AdjacentCounty" -> {"BREVARD", "HIGHLANDS", "INDIANRIVER", 
      "LAKE", "OKEECHOBEE", "ORANGE", "POLK"}|>, <|
    "County" -> "PALMBEACH", 
    "AdjacentCounty" -> {"BROWARD", "GLADES", "HENDRY", "MARTIN", 
      "OKEECHOBEE"}|>, <|"County" -> "PASCO", 
    "AdjacentCounty" -> {"HERNANDO", "HILLSBOROUGH", "PINELLAS", 
      "POLK", "SUMTER"}|>, <|"County" -> "PINELLAS", 
    "AdjacentCounty" -> {"HILLSBOROUGH", "PASCO"}|>, <|
    "County" -> "POLK", 
    "AdjacentCounty" -> {"HARDEE", "HIGHLANDS", "HILLSBOROUGH", 
      "LAKE", "MANATEE", "OKEECHOBEE", "ORANGE", "OSCEOLA", "PASCO", 
      "SUMTER"}|>, <|"County" -> "PUTNAM", 
    "AdjacentCounty" -> {"ALACHUA", "BRADFORD", "CLAY", "FLAGLER", 
      "MARION", "SAINTJOHNS", "VOLUSIA"}|>, <|"County" -> "SANTAROSA",
     "AdjacentCounty" -> {"ESCAMBIA", "OKALOOSA"}|>, <|
    "County" -> "SARASOTA", 
    "AdjacentCounty" -> {"CHARLOTTE", "DESOTO", "MANATEE"}|>, <|
    "County" -> "SEMINOLE", 
    "AdjacentCounty" -> {"BREVARD", "LAKE", "ORANGE", "VOLUSIA"}|>, <|
    "County" -> "SAINTJOHNS", 
    "AdjacentCounty" -> {"CLAY", "DUVAL", "FLAGLER", "PUTNAM"}|>, <|
    "County" -> "SAINTLUCIE", 
    "AdjacentCounty" -> {"INDIANRIVER", "MARTIN", "OKEECHOBEE"}|>, <|
    "County" -> "SUMTER", 
    "AdjacentCounty" -> {"CITRUS", "HERNANDO", "LAKE", "MARION", 
      "PASCO", "POLK"}|>, <|"County" -> "SUWANNEE", 
    "AdjacentCounty" -> {"COLUMBIA", "GILCHRIST", "HAMILTON", 
      "LAFAYETTE", "MADISON"}|>, <|"County" -> "TAYLOR", 
    "AdjacentCounty" -> {"DIXIE", "JEFFERSON", "LAFAYETTE", 
      "MADISON"}|>, <|"County" -> "UNION", 
    "AdjacentCounty" -> {"ALACHUA", "BAKER", "BRADFORD", 
      "COLUMBIA"}|>, <|"County" -> "VOLUSIA", 
    "AdjacentCounty" -> {"BREVARD", "FLAGLER", "LAKE", "MARION", 
      "ORANGE", "PUTNAM", "SEMINOLE"}|>, <|"County" -> "WAKULLA", 
    "AdjacentCounty" -> {"FRANKLIN", "JEFFERSON", "LEON", "LEVY", 
      "LIBERTY"}|>, <|"County" -> "WALTON", 
    "AdjacentCounty" -> {"BAY", "HOLMES", "OKALOOSA", 
      "WASHINGTON"}|>, <|"County" -> "WASHINGTON", 
    "AdjacentCounty" -> {"BAY", "HOLMES", "JACKSON", "WALTON"}|>}]

Then we have a list of cities corresponding to each adjacent county.
The names of the counties are completely capitalized to distinguish their name from those belonging to cities. For example; ALACHUA is a county and Alachua is a city :

cities = Dataset[{<|"AdjacentCounty" -> "ALACHUA", 
    "City" -> {"Alachua", "Archer", "Gainesville", "Hawthorne", 
      "Newberry", "Waldo"}|>, <|"AdjacentCounty" -> "BAKER", 
    "City" -> {"Macclenny"}|>, <|"AdjacentCounty" -> "BAY", 
    "City" -> {"Callaway", "LynnHaven", "MexicoBeach", "PanamaCity", 
      "PanamaCityBeach", "Parker", "Springfield"}|>, <|
    "AdjacentCounty" -> "BRADFORD", 
    "City" -> {"Brooker", "Hampton", "Lawtey", "Starke"}|>, <|
    "AdjacentCounty" -> "BREVARD", 
    "City" -> {"CapeCanaveral", "Cocoa", "CocoaBeach", 
      "IndianHarbourBeach", "Melbourne", "PalmBay", "Rockledge", 
      "SatelliteBeach", "Titusville", "WestMelbourne"}|>, <|
    "AdjacentCounty" -> "BROWARD", 
    "City" -> {"CoconutCreek", "CooperCity", "CoralSprings", 
      "DaniaBeach", "DeerfieldBeach", "FortLauderdale", 
      "HallandaleBeach", "Hollywood", "LauderdaleLakes", "Lauderhill",
       "LighthousePoint", "Margate", "Miramar", "NorthLauderdale", 
      "OaklandPark", "Parkland", "PembrokePines", "Plantation", 
      "PompanoBeach", "Sunrise", "Tamarac", "WestPark", "Weston", 
      "WiltonManors"}|>, <|"AdjacentCounty" -> "CALHOUN", 
    "City" -> {"Blountstown"}|>, <|"AdjacentCounty" -> "CHARLOTTE", 
    "City" -> {"PuntaGorda"}|>, <|"AdjacentCounty" -> "CITRUS", 
    "City" -> {"CrystalRiver", "Inverness"}|>, <|
    "AdjacentCounty" -> "CLAY", 
    "City" -> {"GreenCoveSprings", "KeystoneHeights"}|>, <|
    "AdjacentCounty" -> "COLLIER", 
    "City" -> {"Everglades", "MarcoIsland", "Naples"}|>, <|
    "AdjacentCounty" -> "COLUMBIA", "City" -> {"LakeCity"}|>, <|
    "AdjacentCounty" -> "DESOTO", "City" -> {"Arcadia"}|>, <|
    "AdjacentCounty" -> "DIXIE", 
    "City" -> {"No city is associated with this county."}|>, <|
    "AdjacentCounty" -> "DUVAL", 
    "City" -> {"AtlanticBeach", "Jacksonville", "JacksonvilleBeach", 
      "NeptuneBeach"}|>, <|"AdjacentCounty" -> "ESCAMBIA", 
    "City" -> {"Pensacola"}|>, <|"AdjacentCounty" -> "FLAGLER", 
    "City" -> {"Bunnell", "FlaglerBeach", "PalmCoast"}|>, <|
    "AdjacentCounty" -> "FRANKLIN", 
    "City" -> {"Apalachicola", "Carrabelle"}|>, <|
    "AdjacentCounty" -> "GADSDEN", 
    "City" -> {"Chattahoochee", "Gretna", "Midway", "Quincy"}|>, <|
    "AdjacentCounty" -> "GILCHRIST", 
    "City" -> {"FanningSprings", "Trenton"}|>, <|
    "AdjacentCounty" -> "GLADES", "City" -> {"MooreHaven"}|>, <|
    "AdjacentCounty" -> "GULF", 
    "City" -> {"PortSaintJoe", "Wewahitchka"}|>, <|
    "AdjacentCounty" -> "HAMILTON", "City" -> {"Jasper"}|>, <|
    "AdjacentCounty" -> "HARDEE", 
    "City" -> {"BowlingGreen", "Wauchula"}|>, <|
    "AdjacentCounty" -> "HENDRY", 
    "City" -> {"Clewiston", "LaBelle"}|>, <|
    "AdjacentCounty" -> "HERNANDO", 
    "City" -> {"Brooksville", "WeekiWachee"}|>, <|
    "AdjacentCounty" -> "HIGHLANDS", 
    "City" -> {"AvonPark", "Sebring"}|>, <|
    "AdjacentCounty" -> "HILLSBOROUGH", 
    "City" -> {"PlantCity", "Tampa", "TempleTerrace"}|>, <|
    "AdjacentCounty" -> "HOLMES", "City" -> {"Bonifay"}|>, <|
    "AdjacentCounty" -> "INDIANRIVER", 
    "City" -> {"Fellsmere", "Sebastian", "VeroBeach"}|>, <|
    "AdjacentCounty" -> "JACKSON", 
    "City" -> {"Graceville", "Greenwood", "JacobCity", 
      "Marianna"}|>, <|"AdjacentCounty" -> "JEFFERSON", 
    "City" -> {"Monticello"}|>, <|"AdjacentCounty" -> "LAFAYETTE", 
    "City" -> {"No city is associated with this county."}|>, <|
    "AdjacentCounty" -> "LAKE", 
    "City" -> {"Clermont", "Eustis", "FruitlandPark", "Groveland", 
      "Leesburg", "Mascotte", "Minneola", "MountDora", "Tavares", 
      "Umatilla"}|>, <|"AdjacentCounty" -> "LEE", 
    "City" -> {"BonitaSprings", "CapeCoral", "FortMyers", 
      "FortMyersBeach", "Sanibel"}|>, <|"AdjacentCounty" -> "LEON", 
    "City" -> {"Tallahassee"}|>, <|"AdjacentCounty" -> "LEVY", 
    "City" -> {"CedarKey", "Chiefland", "FanningSprings", 
      "Willinston"}|>, <|"AdjacentCounty" -> "LIBERTY", 
    "City" -> {"Bristol"}|>, <|"AdjacentCounty" -> "MADISON", 
    "City" -> {"Madison"}|>, <|"AdjacentCounty" -> "MANATEE", 
    "City" -> {"AnnaMaria", "Bradenton", "BradentonBeach", 
      "HolmesBeach", "Palmetto"}|>, <|"AdjacentCounty" -> "MARION", 
    "City" -> {"Belleview", "Dunnellon", "Ocala"}|>, <|
    "AdjacentCounty" -> "MARTIN", "City" -> {"Stuart"}|>, <|
    "AdjacentCounty" -> "MIAMI-DADE", 
    "City" -> {"Aventura", "CoralGables", "Doral", "FloridaCity", 
      "Hialeath", "HialeathGardens", "Homestead", "Miami", 
      "MiamiBeach", "MiamiGardens", "MiamiSprings", "NorthBayVillage",
       "NorthMiami", "NorthMiamiBeach", "Opa-locka", "SouthMiami", 
      "SunnyIslesBeach", "Sweetwater", "WestMiami"}|>, <|
    "AdjacentCounty" -> "MONROE", 
    "City" -> {"KeyColonyBeach", "KeyWest", "Layton", "Marathon"}|>, <|
    "AdjacentCounty" -> "NASSAU", "City" -> {"FernandinaBeach"}|>, <|
    "AdjacentCounty" -> "OKALOOSA", 
    "City" -> {"Crestview", "Destin", "FortWaltonBeach", "LaurelHill",
       "MaryEsther", "Niceville", "Valparaiso"}|>, <|
    "AdjacentCounty" -> "OKEECHOBEE", "City" -> {"Okeechobee"}|>, <|
    "AdjacentCounty" -> "ORANGE", 
    "City" -> {"Apopka", "BayLee", "BelleIsle", "Edgewood", 
      "LakeBuenaVista", "Maitland", "Ocoe", "Orlando", "WinterGarden",
       "WinterPark"}|>, <|"AdjacentCounty" -> "OSCEOLA", 
    "City" -> {"Kissimmee", "SaintCloud"}|>, <|
    "AdjacentCounty" -> "PALMBEACH", 
    "City" -> {"Atlantis", "BelleGlade", "BocaRaton", "BoyntonBeach", 
      "DelrayBeach", "Greenacres", "LakeWorth", "Pahokee", 
      "PalmBeachGardens", "RivieraBeach", "SouthBay", "WestPalmBeach",
       "Westlake"}|>, <|"AdjacentCounty" -> "PASCO", 
    "City" -> {"DadeCity", "NewPortRichey", "PortRichey", 
      "SanAntonio", "Zephyrhills"}|>, <|
    "AdjacentCounty" -> "PINELLAS", 
    "City" -> {"BelleairBeach", "BelleairBluffs", "Clearwater", 
      "Dunellin", "Gulfport", "IndianRocksBeach", "Largo", 
      "MadeiraBeach", "Oldsmar", "PinellasPark", "SafetyHarbor", 
      "SaintPetersburg", "Seminole", "SouthPasadena", "TarponSprings",
       "TreasureIsland"}|>, <|"AdjacentCounty" -> "POLK", 
    "City" -> {"Auburndale", "Bartow", "Davenport", "EagleLake", 
      "FortMeade", "Frostproof", "HainesCity", "LakeAlfred", 
      "LakeWales", "Lakeland", "Mulberry", "WinterHaven"}|>, <|
    "AdjacentCounty" -> "PUTNAM", 
    "City" -> {"CrescentCity", "Palatka"}|>, <|
    "AdjacentCounty" -> "SAINTJOHNS", 
    "City" -> {"SaintAugustine", "SaintAugustineBeach"}|>, <|
    "AdjacentCounty" -> "SAINTLUCIE", 
    "City" -> {"FortPierce", "PortSaintLucie"}|>, <|
    "AdjacentCounty" -> "SANTAROSA", 
    "City" -> {"GulfBreeze", "Milton"}|>, <|
    "AdjacentCounty" -> "SARASOTA", 
    "City" -> {"NorthPort", "Sarasota", "Venice"}|>, <|
    "AdjacentCounty" -> "SEMINOLE", 
    "City" -> {"AltamonteSprings", "Casselberry", "LakeMary", 
      "Longwood", "Oviedo", "Sanford", "WinterSprings"}|>, <|
    "AdjacentCounty" -> "SUMTER", 
    "City" -> {"Bushnell", "CenterHill", "Coleman", "Webster", 
      "Wildwood"}|>, <|"AdjacentCounty" -> "SUWANNEE", 
    "City" -> {"LiveOak"}|>, <|"AdjacentCounty" -> "TAYLOR", 
    "City" -> {"Perry"}|>, <|"AdjacentCounty" -> "UNION", 
    "City" -> {"LakeButler"}|>, <|"AdjacentCounty" -> "VOLUSIA", 
    "City" -> {"DaytonaBeach", "DayonaBeachShores", "DeLand", 
      "Edgewater", "FlaglerBeach", "HollyHill", "LakeHellen", 
      "NewSmyrnaBeach", "OakHill", "OrangeCity", "OrmondBeach", 
      "PortOrange", "SouthDaytona"}|>, <|
    "AdjacentCounty" -> "WAKULLA", 
    "City" -> {"SaintMark", "Sopchoppy"}|>, <|
    "AdjacentCounty" -> "WALTON", 
    "City" -> {"DeFuniakSprings", "Freeport"}|>, <|
    "AdjacentCounty" -> "WASHINGTON", 
    "City" -> {"Chipley", "Vernon"}|>}]

My goal is to build the following structured data set table. The table starts like this :

Dataset[{
  <|"County" -> "ALACHUA", "Adjacent_County" -> "BRADFORD", 
   "City" -> "Brooker"|>,
  <|"County" -> "ALACHUA", "Adjacent_County" -> "BRADFORD", 
   "City" -> "Hampton"|>,
  <|"County" -> "ALACHUA", "Adjacent_County" -> "BRADFORD", 
   "City" -> "Lawtey"|>,
  <|"County" -> "ALACHUA", "Adjacent_County" -> "BRADFORD", 
   "City" -> "Starke"|>,
  <|"County" -> "ALACHUA", "Adjacent_County" -> "COLUMBIA", 
   "City" -> "LakeCity"|>,
  <|"County" -> "ALACHUA", "Adjacent_County" -> "GILCHRIST", 
   "City" -> "FanningSprings"|>,
  <|"County" -> "ALACHUA", "Adjacent_County" -> "GILCHRIST", 
   "City" -> "Trenton"|>,
  <|"County" -> "ALACHUA", "Adjacent_County" -> "LEVY", 
   "City" -> "CedarKey"|>,
  <|"County" -> "ALACHUA", "Adjacent_County" -> "LEVY", 
   "City" -> "Chiefland"|>,
  <|"County" -> "ALACHUA", "Adjacent_County" -> "LEVY", 
   "City" -> "FanningSprings"|>,
  <|"County" -> "ALACHUA", "Adjacent_County" -> "LEVY", 
   "City" -> "Williston"|>,
  <|"County" -> "ALACHUA", "Adjacent_County" -> "MARION", 
   "City" -> "Belleview"|>,
  <|"County" -> "ALACHUA", "Adjacent_County" -> "MARION", 
   "City" -> "Dunnellon"|>,
  <|"County" -> "ALACHUA", "Adjacent_County" -> "MARION", 
   "City" -> "Ocala"|>,
  <|"County" -> "ALACHUA", "Adjacent_County" -> "PUTNAM", 
   "City" -> "CrescentCity"|>,
  <|"County" -> "ALACHUA", "Adjacent_County" -> "PUTNAM", 
   "City" -> "Palatka"|>,
  <|"County" -> "ALACHUA", "Adjacent_County" -> "UNION", 
   "City" -> "LakeButler"|>,
  <|"County" -> "BAKER", "Adjacent_County" -> "BRADFORD", 
   "City" -> "Brooker"|>,
  <|"County" -> "BAKER", "Adjacent_County" -> "BRADFORD", 
   "City" -> "Hampton"|>,
  <|"County" -> "BAKER", "Adjacent_County" -> "BRADFORD", 
   "City" -> "Lawtey"|>,
  <|"County" -> "BAKER", "Adjacent_County" -> "BRADFORD", 
   "City" -> "Starke"|>,
  <|"County" -> "BAKER", "Adjacent_County" -> "CLAY", 
   "City" -> "GereenCoveSprings"|>,
  <|"County" -> "BAKER", "Adjacent_County" -> "CLAY", 
   "City" -> "KeyStoneHeights"|>,
  <|"County" -> "BAKER", "Adjacent_County" -> "COLUMBIA", 
   "City" -> "LakeCity"|>,
  <|"County" -> "BAKER", "Adjacent_County" -> "DUVAL", 
   "City" -> "AtlanticBeach"|>,
  <|"County" -> "BAKER", "Adjacent_County" -> "DUVAL", 
   "City" -> "Jacksonville"|>,
  <|"County" -> "BAKER", "Adjacent_County" -> "DUVAL", 
   "City" -> "JacksonvilleBeach"|>,
  <|"County" -> "BAKER", "Adjacent_County" -> "DUVAL", 
   "City" -> "NeptuneBeach"|>,
  <|"County" -> "BAKER", "Adjacent_County" -> "NASSAU", 
   "City" -> "FernandinaBeach"|>,
  <|"County" -> "BAKER", "Adjacent_County" -> "UNION", 
   "City" -> "LakeButler"|>}]

etcetera... The table ends like this:

Dataset[{
  <|"County" -> "WASHINGTON", "Adjacent_County" -> "BAY", 
   "City" -> "Callaway"|>,
  <|"County" -> "WASHINGTON", "Adjacent_County" -> "BAY", 
   "City" -> "LynnHaven"|>,
  <|"County" -> "WASHINGTON", "Adjacent_County" -> "BAY", 
   "City" -> "MexicoBeach"|>,
  <|"County" -> "WASHINGTON", "Adjacent_County" -> "BAY", 
   "City" -> "PanamaCity"|>,
  <|"County" -> "WASHINGTON", "Adjacent_County" -> "BAY", 
   "City" -> "PanamaCityBeach"|>,
  <|"County" -> "WASHINGTON", "Adjacent_County" -> "BAY", 
   "City" -> "Parker"|>,
  <|"County" -> "WASHINGTON", "Adjacent_County" -> "BAY", 
   "City" -> "Springfield"|>,
  <|"County" -> "WASHINGTON", "Adjacent_County" -> "HOLMES", 
   "City" -> "Bonifay"|>,
  <|"County" -> "WASHINGTON", "Adjacent_County" -> "JACKSON", 
   "City" -> "Graceville"|>,
  <|"County" -> "WASHINGTON", "Adjacent_County" -> "JACKSON", 
   "City" -> "Greenwood"|>,
  <|"County" -> "WASHINGTON", "Adjacent_County" -> "JACKSON", 
   "City" -> "JacobCity"|>,
  <|"County" -> "WASHINGTON", "Adjacent_County" -> "JACKSON", 
   "City" -> "Marianna"|>,
  <|"County" -> "WASHINGTON", "Adjacent_County" -> "WALTON", 
   "City" -> "DeFuniakSprings"|>,
  <|"County" -> "WASHINGTON", "Adjacent_County" -> "WALTON", 
   "City" -> "Freeport"|>}]

I have used several commands; for example :

 JoinAcross[counties, adjacentcounties, cities, "city", "Inner"]

but, none of them give me the desired table. Thank you for your help!

$\endgroup$

1 Answer 1

1
$\begingroup$

This task turns out to be a lot easier once you realize that determining the adjacent counties per county is completely unnecessary. We start with a list of counties and their corresponding cities:

ds = Dataset[{<|"County" -> "ALACHUA", 
"City" -> "Alachua"|>, <|"County" -> "ALACHUA", 
"City" -> "Archer"|>, <|"County" -> "ALACHUA", 
"City" -> "Gainesville"|>, <|"County" -> "ALACHUA", 
"City" -> "Hawthorne"|>, <|"County" -> "ALACHUA", 
"City" -> "Newberry"|>, <|"County" -> "ALACHUA", 
"City" -> "Waldo"|>, <|"County" -> "BAKER", 
"City" -> "Macclenny"|>, <|"County" -> "BAY", 
"City" -> "Callaway"|>, <|"County" -> "BAY", 
"City" -> "LynnHaven"|>, <|"County" -> "BAY", 
"City" -> "MexicoBeach"|>, <|"County" -> "BAY", 
"City" -> "PanamaCity"|>, <|"County" -> "BAY", 
"City" -> "PanamaCityBeach"|>, <|"County" -> "BAY", 
"City" -> "Parker"|>, <|"County" -> "BAY", 
"City" -> "Springfield"|>, <|"County" -> "BRADFORD", 
"City" -> "Brooker"|>, <|"County" -> "BRADFORD", 
"City" -> "Hampton"|>, <|"County" -> "BRADFORD", 
"City" -> "Lawtey"|>, <|"County" -> "BRADFORD", 
"City" -> "Starke"|>, <|"County" -> "BREVARD", 
"City" -> "CapeCanaveral"|>, <|"County" -> "BREVARD", 
"City" -> "Cocoa"|>, <|"County" -> "BREVARD", 
"City" -> "CocoaBeach"|>, <|"County" -> "BREVARD", 
"City" -> "IndianHarbourBeach"|>, <|"County" -> "BREVARD", 
"City" -> "Melbourne"|>, <|"County" -> "BREVARD", 
"City" -> "PalmBay"|>, <|"County" -> "BREVARD", 
"City" -> "Rockledge"|>, <|"County" -> "BREVARD", 
"City" -> "SatelliteBeach"|>, <|"County" -> "BREVARD", 
"City" -> "Titusville"|>, <|"County" -> "BREVARD", 
"City" -> "WestMelbourne"|>, <|"County" -> "BROWARD", 
"City" -> "CoconutCreek"|>, <|"County" -> "BROWARD", 
"City" -> "CooperCity"|>, <|"County" -> "BROWARD", 
"City" -> "CoralSprings"|>, <|"County" -> "BROWARD", 
"City" -> "DaniaBeach"|>, <|"County" -> "BROWARD", 
"City" -> "DeerfieldBeach"|>, <|"County" -> "BROWARD", 
"City" -> "FortLauderdale"|>, <|"County" -> "BROWARD", 
"City" -> "HallandaleBeach"|>, <|"County" -> "BROWARD", 
"City" -> "Hollywood"|>, <|"County" -> "BROWARD", 
"City" -> "LauderdaleLakes"|>, <|"County" -> "BROWARD", 
"City" -> "Lauderhill"|>, <|"County" -> "BROWARD", 
"City" -> "LighthousePoint"|>, <|"County" -> "BROWARD", 
"City" -> "Margate"|>, <|"County" -> "BROWARD", 
"City" -> "Miramar"|>, <|"County" -> "BROWARD", 
"City" -> "NorthLauderdale"|>, <|"County" -> "BROWARD", 
"City" -> "OaklandPark"|>, <|"County" -> "BROWARD", 
"City" -> "Parkland"|>, <|"County" -> "BROWARD", 
"City" -> "PembrokePines"|>, <|"County" -> "BROWARD", 
"City" -> "Plantation"|>, <|"County" -> "BROWARD", 
"City" -> "PompanoBeach"|>, <|"County" -> "BROWARD", 
"City" -> "Sunrise"|>, <|"County" -> "BROWARD", 
"City" -> "Tamarac"|>, <|"County" -> "BROWARD", 
"City" -> "WestPark"|>, <|"County" -> "BROWARD", 
"City" -> "Weston"|>, <|"County" -> "BROWARD", 
"City" -> "WiltonManors"|>, <|"County" -> "CALHOUN", 
"City" -> "Blountstown"|>, <|"County" -> "CHARLOTTE", 
"City" -> "PuntaGorda"|>, <|"County" -> "CITRUS", 
"City" -> "CrystalRiver"|>, <|"County" -> "CITRUS", 
"City" -> "Inverness"|>, <|"County" -> "CLAY", 
"City" -> "GreenCoveSprings"|>, <|"County" -> "CLAY", 
"City" -> "KeystoneHeights"|>, <|"County" -> "COLLIER", 
"City" -> "Everglades"|>, <|"County" -> "COLLIER", 
"City" -> "MarcoIsland"|>, <|"County" -> "COLLIER", 
"City" -> "Naples"|>, <|"County" -> "COLUMBIA", 
"City" -> "LakeCity"|>, <|"County" -> "DESOTO", 
"City" -> "Arcadia"|>, <|"County" -> "DIXIE", 
"City" -> "There are no cities in this county."|>, <|"County" -> 
 "DUVAL", "City" -> "AtlanticBeach"|>, <|"County" -> "DUVAL", 
"City" -> "Jacksonville"|>, <|"County" -> "DUVAL", 
"City" -> "JacksonvilleBeach"|>, <|"County" -> "DUVAL", 
"City" -> "Neptune Beach"|>, <|"County" -> "ESCAMBIA", 
"City" -> "Pensacola"|>, <|"County" -> "FLAGLER", 
"City" -> "Bunnell"|>, <|"County" -> "FLAGLER", 
"City" -> "FlaglerBeach"|>, <|"County" -> "FLAGLER", 
"City" -> "Palm Coast"|>, <|"County" -> "FRANKLIN", 
"City" -> "Apalachicola"|>, <|"County" -> "FRANKLIN", 
"City" -> "Carrabelle"|>, <|"County" -> "GADSDEN", 
"City" -> "Chattahoochee"|>, <|"County" -> "GADSDEN", 
"City" -> "Gretna"|>, <|"County" -> "GADSDEN", 
"City" -> "Midway"|>, <|"County" -> "GADSDEN", 
"City" -> "Quincy"|>, <|"County" -> "GILCHRIST", 
"City" -> "FanningSprings"|>, <|"County" -> "GILCHRIST", 
"City" -> "Trenton"|>, <|"County" -> "GLADES", 
"City" -> "MooreHaven"|>, <|"County" -> "GULF", 
"City" -> "PortSaintJoe"|>, <|"County" -> "GULF", 
"City" -> "Wewahitchka"|>, <|"County" -> "HAMILTON", 
"City" -> "Jasper"|>, <|"County" -> "HARDEE", 
"City" -> "BowlingGreen"|>, <|"County" -> "HARDEE", 
"City" -> "Wauchula"|>, <|"County" -> "HENDRY", 
"City" -> "Clewiston"|>, <|"County" -> "HENDRY", 
"City" -> "LaBelle"|>, <|"County" -> "HERNANDO", 
"City" -> "Brooksville"|>, <|"County" -> "HERNANDO", 
"City" -> "WeekiWachee"|>, <|"County" -> "HIGHLANDS", 
"City" -> "AvonPark"|>, <|"County" -> "HIGHLANDS", 
"City" -> "Sebring"|>, <|"County" -> "HILLSBOROUGH", 
"City" -> "PlantCity"|>, <|"County" -> "HILLSBOROUGH", 
"City" -> "Tampa"|>, <|"County" -> "HILLSBOROUGH", 
"City" -> "TempleTerrace"|>, <|"County" -> "HOLMES", 
"City" -> "Bonifay"|>, <|"County" -> "INDIANRIVER", 
"City" -> "Fellsmere"|>, <|"County" -> "INDIANRIVER", 
"City" -> "Sebastian"|>, <|"County" -> "INDIANRIVER", 
"City" -> "VeroBeach"|>, <|"County" -> "JACKSON", 
"City" -> "Graceville"|>, <|"County" -> "JACKSON", 
"City" -> "Greenwood"|>, <|"County" -> "JACKSON", 
"City" -> "JacobCity"|>, <|"County" -> "JACKSON", 
"City" -> "Marianna"|>, <|"County" -> "JEFFERSON", 
"City" -> "Monticello"|>, <|"County" -> "LAFAYETTE", 
"City" -> "There are no cities in this county."|>, <|"County" -> 
 "LAKE", "City" -> "Clermont"|>, <|"County" -> "LAKE", 
"City" -> "Eustis"|>, <|"County" -> "LAKE", 
"City" -> "FruitlandPark"|>, <|"County" -> "LAKE", 
"City" -> "Groveland"|>, <|"County" -> "LAKE", 
"City" -> "Leesburg"|>, <|"County" -> "LAKE", 
"City" -> "Mascotte"|>, <|"County" -> "LAKE", 
"City" -> "Minneola"|>, <|"County" -> "LAKE", 
"City" -> "MountDora"|>, <|"County" -> "LAKE", 
"City" -> "Tavares"|>, <|"County" -> "LAKE", 
"City" -> "Umatilla"|>, <|"County" -> "LEE", 
"City" -> "BonitaSprings"|>, <|"County" -> "LEE", 
"City" -> "CapeCoral"|>, <|"County" -> "LEE", 
"City" -> "Fort Myers"|>, <|"County" -> "LEE", 
"City" -> "FortMyersBeach"|>, <|"County" -> "LEE", 
"City" -> "Sanibel"|>, <|"County" -> "LEON", 
"City" -> "Tallahassee"|>, <|"County" -> "LEVY", 
"City" -> "CedarKey"|>, <|"County" -> "LEVY", 
"City" -> "Chiefland"|>, <|"County" -> "LEVY", 
"City" -> "FanningSprings"|>, <|"County" -> "LEVY", 
"City" -> "Williston"|>, <|"County" -> "LIBERTY", 
"City" -> "Bristol"|>, <|"County" -> "MADISON", 
"City" -> "Madison"|>, <|"County" -> "MANATEE", 
"City" -> "AnnaMaria"|>, <|"County" -> "MANATEE", 
"City" -> "Bradenton"|>, <|"County" -> "MANATEE", 
"City" -> "BradentonBeach"|>, <|"County" -> "MANATEE", 
"City" -> "HolmesBeach"|>, <|"County" -> "MANATEE", 
"City" -> "Palmetto"|>, <|"County" -> "MARION", 
"City" -> "Belleview"|>, <|"County" -> "MARION", 
"City" -> "Dunnellon"|>, <|"County" -> "MARION", 
"City" -> "Ocala"|>, <|"County" -> "MARTIN", 
"City" -> "Stuart"|>, <|"County" -> "MIAMI-DADE", 
"City" -> "Aventura"|>, <|"County" -> "MIAMI-DADE", 
"City" -> "CoralGables"|>, <|"County" -> "MIAMI-DADE", 
"City" -> "Doral"|>, <|"County" -> "MIAMI-DADE", 
"City" -> "FloridaCity"|>, <|"County" -> "MIAMI-DADE", 
"City" -> "Hialeah"|>, <|"County" -> "MIAMI-DADE", 
"City" -> "HialeahGardens"|>, <|"County" -> "MIAMI-DADE", 
"City" -> "Homestead"|>, <|"County" -> "MIAMI-DADE", 
"City" -> "Miami"|>, <|"County" -> "MIAMI-DADE", 
"City" -> "MiamiBeach"|>, <|"County" -> "MIAMI-DADE", 
"City" -> "MiamiGardens"|>, <|"County" -> "MIAMI-DADE", 
"City" -> "MiamiSprings"|>, <|"County" -> "MIAMI-DADE", 
"City" -> "NorthBayVillage"|>, <|"County" -> "MIAMI-DADE", 
"City" -> "NorthMiami"|>, <|"County" -> "MIAMI-DADE", 
"City" -> "NorthMiamiBeach"|>, <|"County" -> "MIAMI-DADE", 
"City" -> "Opa-locka"|>, <|"County" -> "MIAMI-DADE", 
"City" -> "SouthMiami"|>, <|"County" -> "MIAMI-DADE", 
"City" -> "SunnyIslesBeach"|>, <|"County" -> "MIAMI-DADE", 
"City" -> "Sweetwater"|>, <|"County" -> "MIAMI-DADE", 
"City" -> "WestMiami"|>, <|"County" -> "MONROE", 
"City" -> "KeyColonyBeach"|>, <|"County" -> "MONROE", 
"City" -> "KeyWest"|>, <|"County" -> "MONROE", 
"City" -> "Layton"|>, <|"County" -> "MONROE", 
"City" -> "Marathon"|>, <|"County" -> "NASSAU", 
"City" -> "FernandinaBeach"|>, <|"County" -> "OKALOOSA", 
"City" -> "Crestview"|>, <|"County" -> "OKALOOSA", 
"City" -> "Destin"|>, <|"County" -> "OKALOOSA", 
"City" -> "FortWaltonBeach"|>, <|"County" -> "OKALOOSA", 
"City" -> "LaurelHill"|>, <|"County" -> "OKALOOSA", 
"City" -> "MaryEsther"|>, <|"County" -> "OKALOOSA", 
"City" -> "Niceville"|>, <|"County" -> "OKALOOSA", 
"City" -> "Valparaiso"|>, <|"County" -> "OKEECHOBEE", 
"City" -> "Okeechobee"|>, <|"County" -> "ORANGE", 
"City" -> "Apopka"|>, <|"County" -> "ORANGE", 
"City" -> "BayLake"|>, <|"County" -> "ORANGE", 
"City" -> "BelleIsle"|>, <|"County" -> "ORANGE", 
"City" -> "Edgewood"|>, <|"County" -> "ORANGE", 
"City" -> "LakeBuenaVista"|>, <|"County" -> "ORANGE", 
"City" -> "Maitland"|>, <|"County" -> "ORANGE", 
"City" -> "Ocoee"|>, <|"County" -> "ORANGE", 
"City" -> "Orlando"|>, <|"County" -> "ORANGE", 
"City" -> "WinterGarden"|>, <|"County" -> "ORANGE", 
"City" -> "WinterPark"|>, <|"County" -> "OSCEOLA", 
"City" -> "Kissimmee"|>, <|"County" -> "OSCEOLA", 
"City" -> "SaintCloud"|>, <|"County" -> "PALMBEACH", 
"City" -> "Atlantis"|>, <|"County" -> "PALMBEACH", 
"City" -> "BelleGlade"|>, <|"County" -> "PALMBEACH", 
"City" -> "BocaRaton"|>, <|"County" -> "PALMBEACH", 
"City" -> "BoyntonBeach"|>, <|"County" -> "PALMBEACH", 
"City" -> "DelrayBeach"|>, <|"County" -> "PALMBEACH", 
"City" -> "Greenacres"|>, <|"County" -> "PALMBEACH", 
"City" -> "Lake Worth"|>, <|"County" -> "PALMBEACH", 
"City" -> "Pahokee"|>, <|"County" -> "PALMBEACH", 
"City" -> "PalmBeachGardens"|>, <|"County" -> "PALMBEACH", 
"City" -> "RivieraBeach"|>, <|"County" -> "PALMBEACH", 
"City" -> "SouthBay"|>, <|"County" -> "PALMBEACH", 
"City" -> "WestPalmBeach"|>, <|"County" -> "PALMBEACH", 
"City" -> "Westlake"|>, <|"County" -> "PASCO", 
"City" -> "DadeCity"|>, <|"County" -> "PASCO", 
"City" -> "NewPortRichey"|>, <|"County" -> "PASCO", 
"City" -> "PortRichey"|>, <|"County" -> "PASCO", 
"City" -> "SanAntonio"|>, <|"County" -> "PASCO", 
"City" -> "Zephyrhills"|>, <|"County" -> "PINELLAS", 
"City" -> "BelleairBeach"|>, <|"County" -> "PINELLAS", 
"City" -> "BelleairBluffs"|>, <|"County" -> "PINELLAS", 
"City" -> "Clearwater"|>, <|"County" -> "PINELLAS", 
"City" -> "Dunedin"|>, <|"County" -> "PINELLAS", 
"City" -> "Gulfport"|>, <|"County" -> "PINELLAS", 
"City" -> "IndianRocksBeach"|>, <|"County" -> "PINELLAS", 
"City" -> "Largo"|>, <|"County" -> "PINELLAS", 
"City" -> "MadeiraBeach"|>, <|"County" -> "PINELLAS", 
"City" -> "Oldsmar"|>, <|"County" -> "PINELLAS", 
"City" -> "PinellasPark"|>, <|"County" -> "PINELLAS", 
"City" -> "SafetyHarbor"|>, <|"County" -> "PINELLAS", 
"City" -> "SaintPetersburg"|>, <|"County" -> "PINELLAS", 
"City" -> "Seminole"|>, <|"County" -> "PINELLAS", 
"City" -> "SouthPasadena"|>, <|"County" -> "PINELLAS", 
"City" -> "TarponSprings"|>, <|"County" -> "PINELLAS", 
"City" -> "TreasureIsland"|>, <|"County" -> "POLK", 
"City" -> "Auburndale"|>, <|"County" -> "POLK", 
"City" -> "Bartow"|>, <|"County" -> "POLK", 
"City" -> "Davenport"|>, <|"County" -> "POLK", 
"City" -> "EagleLake"|>, <|"County" -> "POLK", 
"City" -> "FortMeade"|>, <|"County" -> "POLK", 
"City" -> "Frostproof"|>, <|"County" -> "POLK", 
"City" -> "HainesCity"|>, <|"County" -> "POLK", 
"City" -> "LakeAlfred"|>, <|"County" -> "POLK", 
"City" -> "LakeWales"|>, <|"County" -> "POLK", 
"City" -> "Lakeland"|>, <|"County" -> "POLK", 
"City" -> "Mulberry"|>, <|"County" -> "POLK", 
"City" -> "WinterHaven"|>, <|"County" -> "PUTNAM", 
"City" -> "CrescentCity"|>, <|"County" -> "PUTNAM", 
"City" -> "Palatka"|>, <|"County" -> "SAINTJOHNS", 
"City" -> "SaintAugustine"|>, <|"County" -> "SAINTJOHNS", 
"City" -> "SaintAugustineBeach"|>, <|"County" -> "SAINTLUCIE", 
"City" -> "FortPierce"|>, <|"County" -> "SAINTLUCIE", 
"City" -> "PortSaintLucie"|>, <|"County" -> "SANTAROSA", 
"City" -> "GulfBreeze"|>, <|"County" -> "SANTAROSA", 
"City" -> "Milton"|>, <|"County" -> "SARASOTA", 
"City" -> "NorthPort"|>, <|"County" -> "SARASOTA", 
"City" -> "Sarasota"|>, <|"County" -> "SARASOTA", 
"City" -> "Venice"|>, <|"County" -> "SEMINOLE", 
"City" -> "AltamonteSprings"|>, <|"County" -> "SEMINOLE", 
"City" -> "Casselberry"|>, <|"County" -> "SEMINOLE", 
"City" -> "LakeMary"|>, <|"County" -> "SEMINOLE", 
"City" -> "Longwood"|>, <|"County" -> "SEMINOLE", 
"City" -> "Oviedo"|>, <|"County" -> "SEMINOLE", 
"City" -> "Sanford"|>, <|"County" -> "SEMINOLE", 
"City" -> "WinterSprings"|>, <|"County" -> "SUMTER", 
"City" -> "Bushnell"|>, <|"County" -> "SUMTER", 
"City" -> "CenterHill"|>, <|"County" -> "SUMTER", 
"City" -> "Coleman"|>, <|"County" -> "SUMTER", 
"City" -> "Webster"|>, <|"County" -> "SUMTER", 
"City" -> "Wildwood"|>, <|"County" -> "SUWANNEE", 
"City" -> "LiveOak"|>, <|"County" -> "TAYLOR", 
"City" -> "Perry"|>, <|"County" -> "UNION", 
"City" -> "LakeButler"|>, <|"County" -> "VOLUSIA", 
"City" -> "DaytonaBeach"|>, <|"County" -> "VOLUSIA", 
"City" -> "DaytonaBeachShores"|>, <|"County" -> "VOLUSIA", 
"City" -> "DeLand"|>, <|"County" -> "VOLUSIA", 
"City" -> "Edgewater"|>, <|"County" -> "VOLUSIA", 
"City" -> "FlaglerBeach"|>, <|"County" -> "VOLUSIA", 
"City" -> "HollyHill"|>, <|"County" -> "VOLUSIA", 
"City" -> "LakeHelen"|>, <|"County" -> "VOLUSIA", 
"City" -> "NewSmyrnaBeach"|>, <|"County" -> "VOLUSIA", 
"City" -> "OakHill"|>, <|"County" -> "VOLUSIA", 
"City" -> "OrangeCity"|>, <|"County" -> "VOLUSIA", 
"City" -> "OrmondBeach"|>, <|"County" -> "VOLUSIA", 
"City" -> "PortOrange"|>, <|"County" -> "VOLUSIA", 
"City" -> "SouthDaytona"|>, <|"County" -> "WAKULLA", 
"City" -> "SaintMarks"|>, <|"County" -> "WAKULLA", 
"City" -> "Sopchoppy"|>, <|"County" -> "WALTON", 
"City" -> "DeFuniakSprings"|>, <|"County" -> "WALTON", 
"City" -> "Freeport"|>, <|"County" -> "WASHINGTON", 
"City" -> "Chipley"|>, <|"County" -> "WASHINGTON", 
"City" -> "Vernon"|>}]

The length of the list is:

Length[ds]

(** answer: 271 **)

The city of Fanning Springs is located at both Gilchrist and Levy counties :

ds[Select[#[[2]] == "FanningSprings" &]]

(** Answer: GILCHRIST FanningSprings LEVY FanningSprings **)

The city of Flagler Beach is located at both Flagler and Volusia counties :

ds[Select[#[[2]] == "FlaglerBeach" &]]

(** Answer: FLAGLER FlaglerBeach VOLUSIA FlaglerBeach **)

There are no cities located at Dixie or Lafayette counties :

ds[Select[#[[2]] == "There are no cities in this county." &]]

(** Answer: DIXIE There are no cities in this county. LAFAYETTE There are no cities in this county. **)

Thank you for your attention. :-)

$\endgroup$
1

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.