 Alteryx began as a mapping and reporting tool. So, undoubtedly there are numerous spatial functions and tools within Alteryx. However, in this blog, I will demonstrate how I used Alteryx to solve one use case. My objective was to find the percentage of locations that fall under a specified radius.

There are two data sets in this example

1. Randomly picked 16 addresses of Australia post around Pyrmont, Sydney area. 2. The center point location I have taken is the Data School Down under address, on a text input file.

## Overview of the workflow: ## Step 1: Convert Postal address to Latitude and Longitude coordinates

I have used the Australia-New Zealand Geocoder tool from the Address palette, to convert each address as a point Spatial Object in both the files. Since the entire address is in a single cell, I have selected ‘single address field’ in the input option. The tool has two output options 1. Geocoded output 2. Summary Output. Use the Geocoded output for the subsequent tools. ## Step 2: Determine the radius of the center point

I have used the Trade Area tool from the Spatial palette to determine the radius around the center point. Specifying a single value will draw a circle, while specifying a range thereafter, with a comma, will draw a donut over the circle. ## Step 3: Spatial Match and Union the data

Spatial Match tool has two inputs, Target and Universe. Connect the Australia post addresses to the Target input and center point radius to the Universe input. For the output, from the dropdown options, select ‘Where Target Within Universe’.

The Spatial Match tool has two outputs, Matched and Unmatched. Matched has records of the addresses that are within radius ranges specified, leaving the rest of the records to the Unmatched output.  The matched section automatically creates a new column, matching the radius for each of the respective address rows. However, for unmatched results, a new column is added using the formula tool. So, both the columns can be combined using union tool. The browse tool here will show the map as below: ## Step 4: Aggregate and append

Use the summarize tool to Groupby and Count the radius-size column. Add another summarize tool to calculate the total count from the count input. Use Append tool to input ‘Targets’ from the first summarize tool and input ‘Source’ from the second summarize tool.

## Step 5: Calculate the percentage

Finally, use the formula tool to calculate the percentage of locations in each of the radius ranges. The results are as below: 