Alteryx Designer Discussions

Find answers, ask questions, and share expertise about Alteryx Designer.
ALTER.NEXT:

Join us on Dec 2 for a half-day virtual analytics + data science event!
US & CA customers only

SAVE YOUR SPOT
It's the most wonderful time of the year - Santalytics 2020 is here! This year, Santa's workshop needs the help of the Alteryx Community to help get back on track, so head over to the Group Hub for all the info to get started!
SOLVED

Population Density

Highlighted
Alteryx Partner

Hi there,

 

I'm having three stores and for each stores I have Customers data including long/lat. I want to calculate the population density for each stores for the customers within 0-5 miles and 5-10 miles.

 

how can I do that ? is there any workflow for this case?

Highlighted
Alteryx Certified Partner
Alteryx Certified Partner

Hi @riam_abdullah I have mocked up a workflow that should work for you. Just replace the map inputs with your data and ensure you use the create points tool for your customer data. Population_Density.JPG

Highlighted
Alteryx
Alteryx

Yes, this is definitely possible. 

 

  • Convert the Lat/Long for the stores to a Spatial Object with the Create Points
  • Build a Trade Area (Tip: you can enter 5,10 and you'll get both trade areas)
    • Note: Use a Spatial Info if you need the area...
  • Separately, Convert the Lat/Long for the customers to a Spatial Object with the Create Points
  • Spatial Match the stores with the customers
  • Aggregate using Summarize and formula to get your density

 

Highlighted
Alteryx
Alteryx

Hi @riam_abdullah,

 

please, see attached.

 

Hope this helps!

 

Giuseppe

Highlighted
Alteryx
Alteryx

Looks like you should be sure of the method now... 3 people replying at the same time...

 

As @JosephSerpis showed... should get you there

Highlighted
Alteryx Partner

@JS420 Thanks for your fast reply, but are you sure from the formula? I thought it's Number of people/miles.

Highlighted
Alteryx Partner

@KaneG Thanks for your explanation, exact same as what @JosephSerpis attached  

Highlighted
Alteryx Partner

@GiuseppeC Sorry but it's not working. 

Highlighted
Alteryx Certified Partner
Alteryx Certified Partner

Hi @riam_abdullah  you are correct in my example i'm treating every point as one single customer. However depends on your customer data you may want to count each customer if one point = 1 customer in each trade area or depending if you have a number of customer per point you might want to summarise. However the formula will always be people/miles as mentioned by you.

Highlighted
Alteryx
Alteryx

Hi @riam_abdullah,

 

I created my workflow with version 2019.2. If you are on a previous version and failing to open, you can extract the .yxzp file using any zip program, open the .yxmd with Notepad and change the version on the second line from 2019.2 to your own.

 

This may be useful for future reference, but I realised I took the same approach as others here, so you should be good to go!

 

Hope this helps,

Giuseppe

Labels