Using Python and YouTube API to Create Analytics on any Channel.

Sdílet
Vložit
  • čas přidán 16. 03. 2021
  • Python and CZcams's API can be used to generate data on any channel on CZcams for free. In this video, we dive into the API to generate some analytics on Mr. Beast's CZcams channel. We will then dig into these analytics and show you how to create some charts with your data. Understanding how to interact with an official API can help you unlock a ton of data sources for all kinds of Python analytics projects.
    I use Deepnote so you can follow along without installing anything on your local computer. Feel free to use any python installation to follow along locally will work as well. The GitHub link has the notebook I created in this video as well.
    -- Resources Used! --
    Getting your API Key - console.developers.google.com/
    Deepnote - deepnote.com/project/401eace2...
    Follow the link and in the top right corner click duplicate notebook!
    Want to chat with me and other programmers join our discord!
    / discord
    GitHub - github.com/ClarityCoders/YouT...
    CZcams API Docs - developers.google.com/youtube...
  • Věda a technologie

Komentáře • 39

  • @ThomaslIngenieur
    @ThomaslIngenieur Před 2 lety +2

    Thanks mate, the best video on CZcams on this topic + massive thanks for sharing the notebook.
    Really clearly explained and fast enough to get an overview of the subject.
    I wish you the best mate - thanks for sharing such a technical & niche topic, despite the low amount of view it is tons of value for each of us really interested.

  • @skony85
    @skony85 Před 2 lety +3

    Great video. I've gone through the whole. Everything is explained clearly. Excellent for beginners in YT API like me.

  • @TinyKideo
    @TinyKideo Před rokem

    The video is clean, easy to understand, and detailed. Can you please explain or make a video for extracting multiple channels information ... example, when you pull a list of 50 or 100 videos, instead, we extract a list of channels, let's say, with more than 50M subscribers?

  • @tempura_edward4330
    @tempura_edward4330 Před 3 lety +2

    Great video! Thank you so much 🙏

  • @sanadhahri5744
    @sanadhahri5744 Před 3 lety

    Thank you great video

  • @aadhavanalakan97
    @aadhavanalakan97 Před 2 lety +2

    Great video. Simply amazing. I did it on a ton of CZcams channels experimenting with it. But I did come across one problem when dealing with bigger channels like CNN, Al Jazeera English, etc. They have nearly 100k videos uploaded and I used the same approach but I wasn't able to get all the videos. The max(len) of the video list was just 20k. Could you throw some light on it? I am struggling to get the full 100k dataset.

  • @eduardocruzism
    @eduardocruzism Před 3 lety +1

    Amazing!

    • @ClarityCoders
      @ClarityCoders  Před 3 lety

      Thank you sir! Have any questions let me know.

  • @JuanGabrielOyolaCardona

    Thanks for sharing 😃🇨🇴💯🌱

  • @larryhuiran
    @larryhuiran Před 2 lety

    really like your video! like to try each of them! LOL

  • @lavidaen3min
    @lavidaen3min Před 2 lety +1

    Is it possible to take the data for each video on a daily basis? Thanks!!

  • @user-ox3qw9vs6t
    @user-ox3qw9vs6t Před 3 lety +3

    great video, any dates on the opencv tutorials?

  • @qiaolimo4976
    @qiaolimo4976 Před 2 lety +1

    why it always shows me "No module named 'googleapiclient'" after I successfully installed client library?

  • @Jammujtaba7
    @Jammujtaba7 Před 2 lety +1

    How u get youtube data Api list string plzzz reply me plz

  • @atb0007
    @atb0007 Před 2 lety +1

    hi guys, i am getting this error on google colab:
    TypeError Traceback (most recent call last)
    in ()
    1 import json
    2 channel_stats = get_channel_stats(youtube, channel_id)
    ----> 3 channel_stats[0]['contentDetails']
    TypeError: 'NoneType' object is not subscriptable
    why am i getting this when i have done everything exactly the same

  • @HarperWolf
    @HarperWolf Před rokem

    i am getting an error for "API_KEY" and im not sure why, it is giving me an error and stopping the code from running, do you know how to fix this?

  • @Mrroy08657
    @Mrroy08657 Před 8 měsíci

    Hi bro , In Video Details , data how to fetch all the ' Video ID ' from Response Object at the same time with others details ? Here , ' Video ID ' can act as the Primary key here in analysis on all vdos .

  • @superhittamilsongs
    @superhittamilsongs Před 2 lety +1

    tag_count= len(video['snippet']['tags'])
    KeyError: 'tags'

  • @meldungenausderforschung6222

    hi, thanks a ton, this was easy to follow :) - My problem: it saves only a fraction of the data in to the csv file. For example, I looked at a channel with 1300 video, but there are only 23 in the file.

    • @ClarityCoders
      @ClarityCoders  Před 3 lety +2

      Sounds like paging is working correct or you are running out of API requests?

    • @meldungenausderforschung6222
      @meldungenausderforschung6222 Před 3 lety +1

      @@ClarityCoders The video data array is filled correctly, so it should not be the number of requests. Can I see somewhere, if I am running out? Also the "df" dictionary gives me results for the first and last video. Only saving it as csv appears to be an issue.

    • @meldungenausderforschung6222
      @meldungenausderforschung6222 Před 3 lety +1

      P.S. I managed to save it as Excel file and that worked. Odd.

  • @rhea2811
    @rhea2811 Před 8 měsíci

    Thanks a lot for the video can you help me to get 100k dataset using this python. Previous comment also stated that it cant mining 100k videos and maximum is at 20k. Do you have any solution or alternative ways?

  • @bloomerboi21
    @bloomerboi21 Před 3 lety +2

    Hey make sure you name your function like getNameSomeThing() instead of get_name_some_thing()
    Because , we have to use camel case for function according to pep-8 styling rules.
    It isn't an error. It's just a best practice.

    • @ClarityCoders
      @ClarityCoders  Před 3 lety +5

      if it's a 50 line script I don't over think pep-8 to be honest. building a software platform sure.

    • @ResistantLaw
      @ResistantLaw Před 2 lety +1

      I thought Python prefers snake case over camel case.

    • @liesdamnlies3372
      @liesdamnlies3372 Před 2 lety +1

      @@ResistantLaw Quite. The OP is either taking the piss or hasn’t actually read PEP-8.
      “mixedCase is allowed only in contexts where that's already the prevailing style (e.g. threading.py), to retain backwards compatibility.”
      To the OP if you’re being serious: PEP-8 stresses consistency above all else.

  • @ThomasBuegel
    @ThomasBuegel Před 4 měsíci

    I did this today, 3 years later - The code is still working but some deprecation warnings. Interesting changes: 1. Dislike Count is allways 0 because it is not more public. MrBeast knows the number, you won't get it anymore. 2. I had to change the dimensions of 'Most Viewed Videos' to 'Billions of Views' and 'Most Video Reactions' to 'Millions of Reactions' 😉

  • @vamsiakula9860
    @vamsiakula9860 Před 3 lety +1

    failed to connect integration!

  • @pradiptahafid
    @pradiptahafid Před 2 lety +1

    dislike does not exist anymore in 2022. just FYI

  • @Kennedy1952
    @Kennedy1952 Před 4 měsíci

    Where is the girl from the miniature?🧐

  • @johnsmitchcpa
    @johnsmitchcpa Před 2 lety +1

    *Hello World*

  • @AlexeySilichenko
    @AlexeySilichenko Před 2 lety +1

    this is not an analytics, you clickbater.