Skip to content

Commit

Permalink
incorect link in README feddelegrand7#12 is now solved
Browse files Browse the repository at this point in the history
  • Loading branch information
gbganalyst committed Jun 14, 2022
1 parent 6bf16e3 commit 6221755
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions README.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -51,20 +51,21 @@ devtools::install_github("feddelegrand7/ralger")
```
## `scrap()`

This is an example which shows how to extract [top ranked universities' names](http://www.shanghairanking.com/ARWU2020.html) according to the ShanghaiRanking Consultancy:
This is an example which shows how to extract [top ranked universities' names](http://www.shanghairanking.com/rankings/arwu/2021) according to the ShanghaiRanking Consultancy:


```{r example}
library(ralger)
my_link <- "http://www.shanghairanking.com/ARWU2020.html"
my_link <- "http://www.shanghairanking.com/rankings/arwu/2021"
my_node <- "#UniversityRanking a" # The element ID , I recommend SelectorGadget if you're not familiar with CSS selectors
my_node <- "a span" # The element ID , I recommend SelectorGadget if you're not familiar with CSS selectors
best_uni <- scrap(link = my_link, node = my_node)
clean <- TRUE # Should the function clean the extracted vector or not ? Default is FALSE
head(best_uni, 10)
best_uni <- scrap(link = my_link, node = my_node, clean = clean)
head(best_uni, 10)
```

Expand Down

0 comments on commit 6221755

Please sign in to comment.