Community Spring Cleaning week is here! Join your fellow Maveryx in digging through your old posts and marking comments on them as solved. Learn more here!

Weekly Challenges

Solve the challenge, share your solution and summit the ranks of our Community!

Also available in | Français | Português | Español | 日本語
IDEAS WANTED

Want to get involved? We're always looking for ideas and content for Weekly Challenges.

SUBMIT YOUR IDEA

Challenge #77: Extending Spatial Lines

JoeM
Alteryx Alumni (Retired)

Happy Monday! Last week's solution can be found HERE!

 

In this week's challenge, a communications company is doing an analysis of fiber runs in the network. The current wiring needs to be extended a certain distance in each direction in a straight line. Take the provided lines and extend them 5 miles on each end. For more intermediate users, create a macro so the user can input the desired extension length for each run.

 

The output should include:
1. Name of the fiber
2. The original spatial line object
3. The new spatial line object
4. New length of line

gnans19
11 - Bolide

Here's my solution. Attached both workflow and macro

 

Result.png

 

 

Spoiler
Spoiler1.png

 

 

map.png

 

 

 

alex
11 - Bolide
Spoiler
I went with finding the slope of the original line and extending it out.  I also decided to use the spatial tools vs. using the spatial formulas.

77a.JPG77b.JPG77c.JPG

Good opportunity to practice with spatial tools that I rarely use.

NicoleJohnson
ACE Emeritus
ACE Emeritus

My solution! I started by going down a trigonometry black hole... that didn't work. (Yet.) So I ended up borrowing a few ideas from @gnans19 and @alex, and then focused on streamlining it once I got it working.

 

I'm convinced there's a trig way to do it though. Stay tuned. :)

 

Spoiler
WeeklyChallenge77.JPG
Joe_Mako
12 - Quasar

Here is a route to get slightly more accurate coordinates, I am sure the expressions could be improved to be even more accurate.

 

Spoiler
andre347
10 - Fireball

Similar approach as one of the workflows above. Good challenge to play with the Spatial tools!

Laurap1228
11 - Bolide

My answer doesn't match exactly, I think it's cause my solution is missing the Smooth tool.

challenge77.jpg

estherb47
15 - Aurora
15 - Aurora

I started down a trig path too, and will get there (just struggling to remember trig!!).

When that wasn't working, found the same solution as many others, with circles and distances. I suppose that's more of a geometric/geospatial approach.

 

Still working on doing this with formulas.... to be continued.....

LordNeilLord
15 - Aurora

Like others I decided to try and figure this out using Trig &  Geometery and then I realised than I have no idea what I'm doing, so I stuck to what I know..

 

Spoiler
Weekly Challenge 77.png
patrick_digan
17 - Castor
17 - Castor

I had a hard time with this one.