Hello. I am a beginner with no previous relevant experience trying to do an exercise in R , topic modelling. I am reading, searching for examples but there are things that i don´t understand.
I am trying to begin by downloading the necessary books, but it doesn´t work. I tried alternatively the following codes (cran.r : gutenbergr: Search and download public domain texts from Project Gutenberg)
type or paste code here
library(gutenbergr)
library(tidytext)
library(stringr)
library(topicmodels)
library(dplyr)
library(tidyr)
titles <- c("Utopia", "The Grand Inquisitor")
books <- gutenberg_works(title %in% titles) %>%
gutenberg_download(meta_fields = "title")
utopia <- gutenberg_download(2130)
the_grand_inquisitor <- gutenberg_download(8578)
I get back :
utopia <- gutenberg_download(2130)
Warning messages:
1: In .f(.x[[i]], ...) :
Could not download a book at http://aleph.gutenberg.org/2/1/3/2130/2130.zip
2: Unknown or uninitialised column:text
.
the_grand_inquisitor <- gutenberg_download(8578)
Warning messages:
1: In .f(.x[[i]], ...) :
Could not download a book at http...
2: Unknown or uninitialised column: text
.
Thank you in advance