#34 Calculate the distance between two points/locations/coordinates in Power BI

Поделиться
HTML-код
  • Опубликовано: 29 окт 2024

Комментарии • 81

  • @excelisfun
    @excelisfun 7 лет назад +2

    Thank you for the Custom Function Distance calculations!

    • @CurbalEN
      @CurbalEN  7 лет назад +2

      +ExcelIsFun They are neat right? :)
      /Ruth

  • @dirksmeyers877
    @dirksmeyers877 6 лет назад +1

    Hi Ruth, This topic is great! I used until now something similar through VBA, but this is more reliable when more data is to process.
    Like Ahmad Hatahet I had also at the start an error with Column 1. In my case it was because My account for using the API was not set correctly yet. Now the error is gone.
    Every video you convince me that thanks to Power Query/BI, VBA is becoming obsolete ;-)
    Once again, Thanks a lot for all your videos with so much enthousiasm! Dirk

    • @CurbalEN
      @CurbalEN  6 лет назад

      Yes! I have to change the code so it gives the google api error and not the power Bi one, the issue is find time to do it ! But glad it worked and you are becoming a power query believer :)
      /Ruth

  • @MrNillock
    @MrNillock 7 лет назад +1

    Awesome! I built a method years ago (still used by my business unit) which uses an array function and re-parameterized Pythagoras for spherical coordinates that will itterate over 10s of thousands of GPS (lat/long) reference points and return the closest point with straightline distances. :) happy to provide that if its of interest

    • @CurbalEN
      @CurbalEN  7 лет назад

      +Collin Taylor That is amazing Collin! :)
      /Ruth

  • @TheDistractionStudio
    @TheDistractionStudio 7 лет назад +1

    Thank You Very Much for taking the time out of your busy schedule and making this awesome tutorial. Greatly appreciated.

    • @CurbalEN
      @CurbalEN  7 лет назад +1

      +rajan77 The pleasure is all mine, happy to help. :)
      /Ruth

  • @storybi8575
    @storybi8575 4 года назад

    Thanks Ruth! This came up as a question at work today, and I thought this sounded like a job for Power BI (Query) :) Thanks!

  • @MarkCBB86
    @MarkCBB86 7 лет назад +1

    That is really cool - Yes please, a more detailed video would be great. Thank you

    • @CurbalEN
      @CurbalEN  7 лет назад +1

      +Mark Blackburn I will, I did that a bit too quickly... I will fix that for next weeks video!
      /Ruth

  • @georgekaroubas6136
    @georgekaroubas6136 7 лет назад +1

    One more great video. Thank you Ruth!

    • @CurbalEN
      @CurbalEN  7 лет назад

      +George Karoubas Thanks to you for watching it and take the time to let me know :)
      /Ruth

  • @varunchandra9828
    @varunchandra9828 9 месяцев назад

    Yes Ruth that could really help

  • @vincentjaugey6921
    @vincentjaugey6921 2 года назад

    Very nice video. Congratulations !

  • @bryon5491
    @bryon5491 4 года назад

    Awesome tutorial Ruth!!! One question I had was what if the use case for defining "to" and "from" are located in the same location variable? in your scenario each row has a two and from lat, long points. The scenario I am trying to solve for is where there is only one variable that has lat and long points and you need to use two variables to define what is "to" and what is "from" destination points. Example ( From destination =( (Location type = "public school A") & "location") To destination = ((Location type = "Subway B") & "location").
    Thought I see if you had a way to code. Again, Awesome tutorial!!!

    • @CurbalEN
      @CurbalEN  4 года назад

      Not sure I follow, I am afraid...

  • @mrquizworthing6741
    @mrquizworthing6741 3 года назад

    If I have a list of 60 different places in Power BI, would this be able to use this to create the distances to the other 59 places and then distances to all other places 60x59x58x57 etc?

  • @Fiktage
    @Fiktage 3 года назад

    Many thanks for your video! Is it possible to compare two list (tables) with coordinates lat, long and to find minimum (or any other specific parameters like less 1 km etc) distance between? Thanks for feedback

  • @thierrycolin695
    @thierrycolin695 7 лет назад +1

    Hi Ruth, Thanks for all useful videos you do. As a beginner, i tried to download you pbix template clicking on your link. It did not work. I got "unable to down load file" message. Is there a specific trick to fix this? Regards

    • @CurbalEN
      @CurbalEN  7 лет назад

      +Thierry Colin Hi Thierry! My server is down at the moment. Please send me an email here and I will email it to you : Curbal.com/Contact

  • @DataSpinners
    @DataSpinners 7 лет назад +1

    Thanks Ruth - looks like you used a custom vis - which one was it?

    • @CurbalEN
      @CurbalEN  7 лет назад

      +DataSpinners Hi! It is this one:
      Flow Map
      store.office.com/en-us/app.aspx?assetid=WA104380901&sourcecorrid=df5b5ee8-a8cc-4add-a24c-dab978c53752&searchapppos=19&ui=en-US&rs=en-US&ad=US&appredirect=false
      /Ruth

    • @DataSpinners
      @DataSpinners 7 лет назад +1

      Fantastic many thanks

    • @CurbalEN
      @CurbalEN  7 лет назад

      +DataSpinners You welcome! :) and have a nice weekend!
      /Ruth

  • @vikasdad6936
    @vikasdad6936 3 года назад

    Hi , Can we do the same in Power Query . Can you elaborate how the Distance function was created. I have the Lat & Long for all sites & i need to compute the distance amongst them

  • @pooneh1894
    @pooneh1894 4 года назад

    Thanks for the video. Can you also show how to display these routes on the map? right now they are just lines but how can I show the routes on map in power bi?

  • @mercadomarcos
    @mercadomarcos 7 лет назад +1

    hello! Thanks for these helpful videos. Is there a way to show the actual routes of multiple Origins & Destinations on a map (Google or other) instead of just getting the distance & time values between them? Thanks!

    • @CurbalEN
      @CurbalEN  7 лет назад +1

      +Marcos Mercado Hi Marcos!! Have you tried this one?
      store.office.com/en-us/app.aspx?assetid=WA104380985&sourcecorrid=b88d2b2a-82f7-425c-87aa-bbd460aa43ae&searchapppos=24&ui=en-US&rs=en-US&ad=US&appredirect=false
      I haven't tried it myself but it seems it should do what you are asking for.
      Let me know if it works !
      /Ruth

    • @mercadomarcos
      @mercadomarcos 7 лет назад +1

      I believe we have and didn't work as expected, but we'll give it another try. Saludos y gracias!

    • @CurbalEN
      @CurbalEN  7 лет назад +1

      +Marcos Mercado Perfect, after my vacation I will do a video on it to see what it does :)
      /Ruth

  • @balaji_906
    @balaji_906 3 года назад

    I am looking for videos on DAX to calculate distance between two points using lat and long. Any help is appreciated!

  • @AlessandroSilva-dl3vq
    @AlessandroSilva-dl3vq 4 года назад

    Seria possível colocar o ponto inicial e o final em um tipo de filtro direto no painel e assim apresentar a rota no mapa?
    Obrigado pelas dicas aprendendo muito

  • @rrrprogram8667
    @rrrprogram8667 7 лет назад +1

    Good one .... So, you have chosen Mumbai and Bangalore... :D... have u ever been to India ?

    • @CurbalEN
      @CurbalEN  7 лет назад

      +RRR program Hi!
      I have dear friends in India, but unfortunately I haven't been able to visit them there yet. I am planing a trip for next year to Gujarat where they live. I am really looking forward to it :)
      I guess my subconscious betrayed me when I chose the cities for the video!!
      Where in India do you come from?
      /Ruth

    • @rrrprogram8667
      @rrrprogram8667 7 лет назад +1

      Its Hyderabadddd.... land of Biryani :D..
      Advance welcome to India.... Do visit in winter .. probably anywhere between Nov to Feb..... Else there would be soaring heat.. Don't miss Rajasthan...

    • @CurbalEN
      @CurbalEN  7 лет назад

      +RRR program Yes, they told me that too 😂! November is a perfect time to go as it is so dark and cold in Sweden and if I am lucky I might be able to attend a wedding, perfect opportunity to embrace Indian culture!
      Have to check where you live :)
      /Ruth

    • @rrrprogram8667
      @rrrprogram8667 7 лет назад +1

      Great......Have real fun :)....

    • @CurbalEN
      @CurbalEN  7 лет назад

      +RRR program Yeah!! 😊
      /Ruth

  • @aaronsaunders4269
    @aaronsaunders4269 3 года назад

    Hi Curbal, thanks so much for this solution! It's really awesome! Is there a way we can edit the function within Power Query to return the distance in metres, as opposed to text? e.g. "1000" instead of "1 km"

    • @CurbalEN
      @CurbalEN  3 года назад +1

      Hi Aaron,
      Text.AfterDelimiter([distance], " ") should do it!

  • @PLBL
    @PLBL 4 года назад

    Hey! Is this a function we can create ourselves? Or do we need to purchase it?

    • @CurbalEN
      @CurbalEN  4 года назад

      You can create it yourself:)

  • @marcelammelo
    @marcelammelo 6 лет назад +1

    Amazing!

  • @thiagoriosbarros2287
    @thiagoriosbarros2287 5 лет назад

    Thank you, Ruth! Can you help me with the access to Download Center? I'm trying do get the PBIX file here but apparently the Download Center isnt available.

    • @CurbalEN
      @CurbalEN  5 лет назад +1

      Hi Thiago, i just checked and it is live. Can you check with another Wi-Fi or private computer? Cloud services are often blocked by companies.
      Let me know!
      -Ruth

    • @thiagoriosbarros2287
      @thiagoriosbarros2287 5 лет назад

      @@CurbalEN You're right! It works. Thank you again, Ruth.

  • @MichaelSherif-z5z
    @MichaelSherif-z5z Год назад

    How to add more modes for example vessels ?

  • @achielv5337
    @achielv5337 5 лет назад

    Looks really good ! thanks for this. How can I access the .pbit file? the link in the description gives an error. Many thanks again for sharing this video !

  • @kabelomzwinila6844
    @kabelomzwinila6844 6 лет назад +1

    Great video! Thank you Ruth, this is very helpful. However, i'm also unable to download the .pbit file :(

    • @CurbalEN
      @CurbalEN  6 лет назад

      Check this out:
      m.ruclips.net/video/NzmZcuyjWB4/видео.html
      /Ruth

  • @CloudhoundCoUk
    @CloudhoundCoUk 7 лет назад +1

    Fantastic

    • @CurbalEN
      @CurbalEN  7 лет назад

      +Cloud Hound Thanks!
      /Ruth

  • @PLBL
    @PLBL 4 года назад

    As soon as I use the API call in my code, it works perfectly in the editor, but as soon as I publish, I am unable to schedule a refresh. I each time need to refresh on my local and republish. Does anyone know why this is?

  • @dagaal92
    @dagaal92 7 лет назад +1

    Hi,
    The Link to pbix template it's broken. :(
    I would be very grateful.

    • @CurbalEN
      @CurbalEN  7 лет назад

      Hi Daniel,
      Here is the new link:
      gofile.me/2kEOD/BGLRw3qdv
      /Ruth

    • @dagaal92
      @dagaal92 7 лет назад +1

      ¡ Thanks so much !

    • @CurbalEN
      @CurbalEN  7 лет назад

      +Daniel Garcia Alvarez De nada ;)
      /Ruth

  • @avulasandeep
    @avulasandeep 6 лет назад +1

    how to create lat and long function ....can you please explain detailed????

    • @CurbalEN
      @CurbalEN  6 лет назад

      Hi Sandeep, what do you mean exactly?
      /Ruth

    • @avulasandeep
      @avulasandeep 6 лет назад +1

      i have some data related to long and lat for finding the distance and i had created parameters like above video but i am unable to create function as above it showing the all the table when i use invoke function....can you please help me ....i will send the excel sheet with lat and long need to find the distance

    • @CurbalEN
      @CurbalEN  6 лет назад

      Hi Sandeep, I am not able to provide individual support, I get too many questions. Could you please post this in the Power BI community?
      Thanks!
      /Ruth

  • @IgorGeorgeAbdo
    @IgorGeorgeAbdo 5 лет назад

    Hi Ruth!!! I am not able to download the .pbit file
    thanskss

    • @CurbalEN
      @CurbalEN  5 лет назад +1

      Hi Igor, all download files have moved to the download center at Curbal.com

    • @IgorGeorgeAbdo
      @IgorGeorgeAbdo 5 лет назад

      @@CurbalEN Thankssss Ruth!!!! It's amazing!!

    • @CurbalEN
      @CurbalEN  5 лет назад

      Yey!! Glad you found it and it was useful :)))
      /Ruth

  • @vicnatal
    @vicnatal 5 лет назад

    Hi there! Can you upload the .pbit file again? I cannot download it

    • @CurbalEN
      @CurbalEN  5 лет назад

      Hi, all download files have been moved to the download center at Curbal.com
      /Ruth

  • @richardlee7311
    @richardlee7311 5 лет назад

    The file doesn't seem to work anymore it is putting an error of can not find column 1 all the time

    • @CurbalEN
      @CurbalEN  5 лет назад

      That means that something is wrong with your api key. Check that is valid.
      /Ruth

    • @richardlee7311
      @richardlee7311 5 лет назад

      I've only just got the api key tried it a few times same result @@CurbalEN

    • @CurbalEN
      @CurbalEN  5 лет назад

      It could be something wrong in the URL that is sent to google API. You need to check everything very careful, I got that error all the time in the beginning.
      For more personalized help, please contact the Power bi community and follow this steps:
      m.ruclips.net/video/oXFOebuvRz0/видео.html
      /Ruth

    • @richardlee7311
      @richardlee7311 5 лет назад

      followed each step several times. Same result, most of the google screens are now updated but I would assume the result would be the same. I will try something else.@@CurbalEN

    • @CurbalEN
      @CurbalEN  5 лет назад

      Hi Richard,
      I checked to make sure the code is still ok and it works with my API key.
      I modified the function a bit so you can get the error message from google API and hopefully that will help you troubleshoot.
      Download the file again #34.
      /Ruth

  • @jamesdoku7807
    @jamesdoku7807 5 лет назад

    Hello l cant download the file please help

    • @CurbalEN
      @CurbalEN  5 лет назад

      You will find it in the download center at Curbal.com
      /Ruth

  • @ZombieBrainz
    @ZombieBrainz 7 лет назад +2

    Hide your key @ 4:14 ;-)

    • @CurbalEN
      @CurbalEN  7 лет назад

      +Zombie Brainz Oh dear, thanks! Better to reset it instead! Done ✅!
      /Ruth