Práctica calificada. Septiembre 19.
LINKtennisMen = "https://en.wikipedia.org/wiki/List_of_Wimbledon_gentlemen%27s_singles_champions"
library(htmltab)
Tabla= (htmltab(doc = LINKtennisMen,which = '//*[@id="mw-content-text"]/div/table[4]'))
names(Tabla)
## [1] "Year" "Country" "Champion"
## [4] "Country" "Runner-up" "Score in the final"
Tabla=Tabla[2]
names(Tabla)
## [1] "Country"
head(Tabla)
## Country
## 2 AUS
## 3 AUS
## 4 AUS
## 5 AUS
## 6 USA
## 7 TCH
str(Tabla)
## 'data.frame': 52 obs. of 1 variable:
## $ Country: chr " AUS" " AUS" " AUS" " AUS" ...
library(ggplot2)
base = ggplot(data = Tabla,aes(x="Country"))