Get YouTube data for analysis
Project description
Youtube-Info
Make YouTube queries and get text information from videos (including captions) ready for Jupyter Notebooks.
Installation
pip install youtubeinfo
USAGE
Create a search object
import youtubeinfo.core as yt
yt_search = yt.search("Test", developer_key=<YOUTUBE_DEVELOPER_KEY>)
yt_search.df # DataFrame with YouTube info (likes, views, title, etc.)
Developer key
YOUTUBE_DEVELOPER_KEY has to be created following https://developers.google.com/youtube/registering_an_application?hl=en and can be set as environment variable
Developer key as environment variable
Linux: edit ~/.profile and add as last line of code
export YOUTUBE_DEVELOPER_KEY=<YOUTUBE_DEVELOPER_KEY>
Captions
To get captions, use the argument captions=True
import youtubeinfo.core as yt
# YOUTUBE_DEVELOPER_KEY is not necessary if was set as environment variable
yt_search = yt.search("Test", caption=True)
yt_search.df # A new column with captions "video_caption" will appear
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
youtubeinfo-0.1.3.tar.gz
(16.1 kB
view hashes)
Built Distribution
Close
Hashes for youtubeinfo-0.1.3-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8a5adf9394efe7b1796dcb1d73bdfe463833bd2d1f93e1581fe72062de2d217f |
|
MD5 | 9b9a55ea9227ceac76e137fa4db68292 |
|
BLAKE2b-256 | c8bdd585442f259ccae35e43760b402f770e62082160d5ae5543aed8fae349d9 |