videoListDownloadByTable: Download YouTube videos/audios by providing a table of...

Description Usage Arguments Examples

View source: R/videoListDownloadByTable.R

Description

Download YouTube videos/audios by providing a table of video/audio list.

Usage

1
2
3
4
5
6
7
8
9
videoListDownloadByTable(
  fileList,
  fileTable = NULL,
  path,
  bothVideoAudio = TRUE,
  priority = c("mp4", "best", "audio only"),
  id = NULL,
  sleepTime = 10
)

Arguments

fileList

the file name of video/audio list table. This table is a csv file generated by videoListTable function. The columns of this table are 'rowNumber', 'Orders', 'VideoTitles', 'fileName', and 'URL', in which 'URL' is most important information. If fileTable is provided, then this argument is not used.

fileTable

the file table returned by videoListTable function. If fileTable is provided, then fileList argument is not used.

path

the path to save video/audio files.

bothVideoAudio

logic, whether download both audio and video, it should be FALSE if only downloading audio or video. The default is TRUE.

priority

the file format to download. The option can be any one (or combination) of "mp4", "best", "audio only", "mp3", "webm", the default is c("mp4", "best", "audio only"), which means the downloader will look for mp4 file first, if this file does not exist, then the downloader will look for the best file marked by YouTube, then look for only audio file.

id

numeric or NULL, the index of rows of the 'fileList' table to download. The default is NULL.

sleepTime

numeric, the time to pause to prevent YouTube blocking. The default is 10 second

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
{
## Not run: 
file = "fileNameOrders.csv"
folderName = "./fileByTable"
#### download video by fileNameOrders.csv table
newFolder = videoListDownloadByTable(fileList = file,
                                     folderName = folderName,
                                     bothVideoAudio = TRUE,
                                     priority = c("best"),
                                     sleepTime = 10,
                                     id = c(1, 2, 5, 9))

## End(Not run)
}

paodan/youtubeDownloader documentation built on Nov. 15, 2020, 9:48 p.m.