Imports html files already downloaded into a character vector.

ImportHtml(from = "articles", sample = NULL, project = NULL,
  website = NULL, pathToHtmlFolder = "", sort = TRUE,
  recursive = FALSE, includePath = FALSE)

Arguments

from

Allows to choose which type of contents to import. Can be either "articles" or "index".

sample

Defaults to NULL. If a numeric value n is provided, then instead of importing all html files it imports n random files.

project

Name of 'castarter' project. Must correspond to the name of a folder in the current working directory.

website

Name of a website included in a 'castarter' project. Must correspond to the name of a sub-folder of the project folder.

sort

Logical, defaults to TRUE. For folders downloaded through 'castarter' (e.g. with DownloadContents) this should be left to TRUE, otherwise mismatch between articlesLinks and imported documents is due to occur.

recursive

Value is passed to list.files function when using the pathToHtmlFolder option.

Value

A character vector of html file, or a data frame if includePath is set to TRUE.

Examples

# NOT RUN {
articlesHtml <- ImportHtml(from = articles, project, website)
# }