rafalab / dsbook

Repository for data science book
Other
1.09k stars 1.07k forks source link

Building instructions #90

Closed Emmanuel-R8 closed 5 years ago

Emmanuel-R8 commented 5 years ago

I have been trying to build the pdf locally and have been completely unsuccessful. Are there any available instructions?

If not, I can provide details of the errors where I am stumped.

rafalab commented 5 years ago

I recommend using RStudio for this. First step is to opening the dsbook.Rproj file (double click or open project from RStudio). Then there is a build book under the build tab on the upper right pane. For this to work all the packages used in the book along with latex need to be installed. I think these are all of the packages:

install.packages("tidyverse, dslabs, gridExtra, dplyr, ggplot2, ggthemes, ggrepel, 
ggridges, HistData, scales, RColorBrewer, scatterplot3d, VennDiagram, gtools, 
NHANES, purrr, readr, readxl, ggflags, countrycode, lubridate, tidytext, broom, 
gutenbergr, caret, gganimate, pdftools, matrixStats, randomForest, genefilter, 
knitr, MASS, rpart, rafalib, rvest, jsonlite, textdata, stringr, english, tidyr, 
Lahman, reshape2, lpSolve")

Hope this helps!

Emmanuel-R8 commented 5 years ago

I had all those steps ticked off already. I note that more packages are needed (e.g. e1071).

The key error that stopped everything (and then I recalled your video on text sentiments) was the request to approve licenses to download data.

Maybe you could make a note of this in the Readme?

rafalab commented 5 years ago

Good catch. Would you be interested in writing a how-to on creating a pdf of the book from scratch? I would be more than happy to add to it to the repo.

Emmanuel-R8 commented 5 years ago

I might do that and a few other things I may catch along the way. But it might take some time since I don't know how to simulate a blank R install (short or uninstalling all the packages).