3 Replies Latest reply on Jan 5, 2019 2:17 PM by Allan Walker

# Mapping Current Flights with Arcs

I'm hoping there's a Tableau expert who can help me.

Goal is to map current flights with arcs. I've followed article to get started Mapping Real Time Flights (Advanced) | Tableau Public (beginner section). I don't use python but would love to accomplish a similar view.

To isolate the current flights going on I used this calc:

NOW() > [Dep Date (US CT)] AND NOW() < [Arr Date (US CT)]

Also figured out how to know how completed the flight is:

(NOW()-[Dep Date (US CT)]) / ([Arr Date (US CT)] - [Dep Date (US CT)])

To plot how far the flight has gone so far I used these Long/Lat calcs:

Lat:

IF [Path Order] = 2 THEN

( [ArrCityLat] - [DepCityLat] ) * [Completion %] + [DepCityLat]

END

Lon:

IF [Path Order] = 2 THEN

( [ArrCityLong] - [DepCityLong] ) * [Completion %] + [DepCityLong]

END

I've plotted this out and used this blog to add arcs Great Arcs in Tableau by Chris DeMartini — DataBlick

Two things I'd like to fix  - 1) The arcs to not hit the top of the map (just looks bad)

2) I'd love the arc to be based on the destination but to plot how far along it is based on the completion

Any and all help is really appreciated. I wish I could share my workbook but data is sensitive.

Thank you!
Shelby

• ###### 1. Re: Mapping Current Flights with Arcs

Hi Shelby,

If you have 2018.2 you can use the following blog article (updated for newest software release) to use a more amenable method of achieving what you want to do.  Timely answer to a question.  This was just published a couple of days ago.  Three different data source methodologies.

Thx, Don

• ###### 2. Re: Mapping Current Flights with Arcs

I don't have 2018.2 and we have a lag on getting upgrades so I'm not sure when I'll get to use this awesome update. Just hoping someone can help me with using 10.5.

Thanks!
Shelby

• ###### 3. Re: Mapping Current Flights with Arcs

Hi Shelby,

My advice would be the following:

2. On the top menu bar, Click Plugins -> Manage and Install Plugins
3. Search for Shape Tools plugin and install
4. On the top menu bar, Click Vector -> Shape Tools -> XY to line
5. Assuming your data is as follows: Source_Lat, Source_Long, Dest_Lat, Dest_Long apply the following to the dialogue box:

With the OpenFlights data you'll end up with this:

One more thing to do in QGIS:

On the top menu bar, Click Vector -> Geometry Tools -> Check Validity.  This ensures you don't get one of those horrible "LineStrings must have at least two co-ordinates" messages in Tableau.

Save the "Valid Output" line by right clicking and save as ESRI Shapefile.

Connect to Tableau:

and hey presto, Point & Click Great Arcs (geodesic lines) in Tableau.

1. Because you are using Web Mercator, arcs will bump along the top of the map.  Sorry, the world is not flat!
2. Plotting progress of a real aircraft over these routes wouldn't be sensible.  Like, at all.  Real life stuff like weather and stacking over busy airports gets in the way.  If you want to plot aircraft positions, then you probably want to look at something like ADSB Exchange - here's an example I built with Anya A'Hearn and Joe Mako :

Anything is possible ^_^

1 of 1 people found this helpful