What algorithm would you use to find the "best" file by speed?

Which speed is most important?

- Download speed?
- Upload speed?
- Ping times?

a. An average of all three? b. The total of all three? c. The mean?

Once I have a bunch of speed-tagged ovpn files, there is a need to

***sort***them by fastest file, which is easy enough to sort:

$ ls vpngate_DE_09_Saarland_Neunkirchen_95.88.252.235-vpn149931469.opengw.net_tcp995_20160308_0.46dn_0.38up_738ms.ovpn vpngate_DE_09_Saarland_Neunkirchen_95.88.252.235-vpn149931469.opengw.net_tcp995_20160310_1.22dn_0.51up_582ms.ovpn vpngate_DE_09_Saarland_Neunkirchen_95.88.252.235-vpn149931469.opengw.net_udp1195_20160308_1.07dn_0.17up_325ms.ovpn vpngate_DE_09_Saarland_Neunkirchen_95.88.252.235-vpn149931469.opengw.net_udp1195_20160310_1.50dn_1.59up_320ms.ovpn vpngate_DE_na_na_na_176.199.177.41-vpn281592706.opengw.net_tcp1921_20160310_1.21dn_0.69up_595ms.ovpn vpngate_DE_na_na_na_213.136.71.159-213.136.71.159_udp1195_20160304_5.70dn_1.42up_287ms.ovpn vpngate_DE_na_na_na_213.136.71.159-213.136.71.159_udp1195_20160307_5.60dn_3.63up_284ms.ovpn vpngate_DE_na_na_na_213.136.71.159-vpn755373027.opengw.net_tcp995_20160304_2.07dn_0.00up_500ms.ovpn vpngate_DE_na_na_na_213.136.71.159-vpn755373027.opengw.net_tcp995_20160307_0.99dn_0.00up_521ms.ovpn vpngate_DE_na_na_na_213.136.71.159-vpn755373027.opengw.net_udp1195_20160304_5.55dn_5.54up_278ms.ovpn vpngate_DE_na_na_na_213.136.71.159-vpn755373027.opengw.net_udp1195_20160307_5.48dn_3.81up_278ms.ovpn vpngate_DE_na_na_na_217.240.31.81-217.240.31.81_udp1195_20160309_0.73dn_0.00up_534ms.ovpn vpngate_DE_na_na_na_217.240.31.81-vpn187314653.opengw.net_udp1195_20160308_2.46dn_0.00up_482ms.ovpn vpngate_DE_na_na_na_5.189.135.48-5.189.135.48_udp1195_20160305_3.37dn_1.48up_299ms.ovpn

$ alias vpnsort='vpnsort.sh' $ cat $(which vpnsort.sh) #!/bin/bash # vpnsort lists speed-tagged files slowest to fastest ls ***dn_***up_***ms***.ovpn | awk -F"_" '{print $9,$10,$11,$0}' | sort -n exit 0 ## End ##

$ vpnsort 0.46dn 0.38up 738ms.ovpn vpngate_DE_09_Saarland_Neunkirchen_95.88.252.235-vpn149931469.opengw.net_tcp995_20160308_0.46dn_0.38up_738ms.ovpn 0.73dn 0.00up 534ms.ovpn vpngate_DE_na_na_na_217.240.31.81-217.240.31.81_udp1195_20160309_0.73dn_0.00up_534ms.ovpn 0.99dn 0.00up 521ms.ovpn vpngate_DE_na_na_na_213.136.71.159-vpn755373027.opengw.net_tcp995_20160307_0.99dn_0.00up_521ms.ovpn 1.07dn 0.17up 325ms.ovpn vpngate_DE_09_Saarland_Neunkirchen_95.88.252.235-vpn149931469.opengw.net_udp1195_20160308_1.07dn_0.17up_325ms.ovpn 1.21dn 0.69up 595ms.ovpn vpngate_DE_na_na_na_176.199.177.41-vpn281592706.opengw.net_tcp1921_20160310_1.21dn_0.69up_595ms.ovpn 1.22dn 0.51up 582ms.ovpn vpngate_DE_09_Saarland_Neunkirchen_95.88.252.235-vpn149931469.opengw.net_tcp995_20160310_1.22dn_0.51up_582ms.ovpn 1.50dn 1.59up 320ms.ovpn vpngate_DE_09_Saarland_Neunkirchen_95.88.252.235-vpn149931469.opengw.net_udp1195_20160310_1.50dn_1.59up_320ms.ovpn 2.07dn 0.00up 500ms.ovpn vpngate_DE_na_na_na_213.136.71.159-vpn755373027.opengw.net_tcp995_20160304_2.07dn_0.00up_500ms.ovpn 2.46dn 0.00up 482ms.ovpn vpngate_DE_na_na_na_217.240.31.81-vpn187314653.opengw.net_udp1195_20160308_2.46dn_0.00up_482ms.ovpn 3.37dn 1.48up 299ms.ovpn vpngate_DE_na_na_na_5.189.135.48-5.189.135.48_udp1195_20160305_3.37dn_1.48up_299ms.ovpn 5.48dn 3.81up 278ms.ovpn vpngate_DE_na_na_na_213.136.71.159-vpn755373027.opengw.net_udp1195_20160307_5.48dn_3.81up_278ms.ovpn 5.55dn 5.54up 278ms.ovpn vpngate_DE_na_na_na_213.136.71.159-vpn755373027.opengw.net_udp1195_20160304_5.55dn_5.54up_278ms.ovpn 5.60dn 3.63up 284ms.ovpn vpngate_DE_na_na_na_213.136.71.159-213.136.71.159_udp1195_20160307_5.60dn_3.63up_284ms.ovpn 5.70dn 1.42up 287ms.ovpn vpngate_DE_na_na_na_213.136.71.159-213.136.71.159_udp1195_20160304_5.70dn_1.42up_287ms.ovpn

Notice the "average" numbers of the penultimate file in the list above may indicate it's faster overall than the last file, which is the fastest by download speed.

So I'm not sure ***what*** algorithm to use for choosing the "best" speed.

What algorithm would you use to find the "best" file by speed?