Hello,
I am a beginner with Alteryx, and I am struggling to figure out how to combine 2 different columns of data I have: "latitude" and "longitude".
The data for these two are currently float. However, I want to combine them to create a new column called "Base Location" with a formula: [latitude] + "," [location]. However, to do this, it says that it needs to be a string.
However, I prefer to do it in a way that makes "Base Location" a numeric value because I plan on running a summarize tool that will conduct the "minimum of base location" and "maximum of base location". Then, from there, I plan on subtracting the differences of both minimum and maximum of base location to have a new column called "Total Distance Moved".
Any help would be much appreciated.
Thank you,
Hannah Reed
Solved! Go to Solution.
Hello!
Thank you for getting back to me.
Now that you ask that question, minimum and maximum may not be something I would want to do.
I just want to calculate how far they have traveled based off their latitude and longitude. Each device_id has multiple records of different latitudes and longitudes. I would like to somehow calculate the total distance they moved.
Hi,
Understood! You might want to use spatial tools for that, I think there was a similar problem in the weekly challenge right here.
Start by using the 'Create Points' tool under Spatial tools to create centroids for each point, and the workflow in the challenge should help you get the line and the distance.
Nivi
You'd need to start by creating spatial points for the beginning and ending points using the longitude and latitude values and the Create Points tool. You can then use the Distance tool to find the distance traveled.
See below for the tool mastery pages that might be of help: