10.33 Location
20180723 From our review of the data so far we start to
make some observations about the character variables. The first is
location
. We note that several locations were reported in
the above exploration of the dataset. We can confirm the number of
locations by counting the number of base::unique() values
the variable has in the original dataset.
# How many locations are represented in the dataset.
$location %>%
dsunique() %>%
length()
## [1] 49
We may not know in general what other locations we will come across in related datasets and we already have quite a collection of \Sexpr{ds\(location%>%unique()%>%length()} %\) locations. We will retain this variable as a character data type.
Here is a list of locations and their frequencies in the dataset.
$location %>%
dstable()
## .
## Adelaide Albany Albury AliceSprings
## 3924 3983 3984 3984
## BadgerysCreek Ballarat Bendigo Brisbane
## 3936 3984 3975 4137
## Cairns Canberra Cobar CoffsHarbour
## 3984 4380 3953 3953
## Dartmoor Darwin GoldCoast Hobart
## 3953 4137 3984 4137
## Katherine Launceston Melbourne MelbourneAirport
## 2522 3984 4137 3953
## Mildura Moree MountGambier MountGinini
## 3953 3953 3983 3984
## Newcastle Nhil NorahHead NorfolkIsland
## 3984 2522 3948 3953
## Nuriootpa PearceRAAF Penrith Perth
## 3952 3952 3983 4136
## PerthAirport Portland Richmond Sale
## 3952 3953 3953 3953
## SalmonGums Sydney SydneyAirport Townsville
## 3906 4288 3953 3984
## Tuggeranong Uluru WaggaWagga Walpole
## 3983 2522 3953 3949
## Watsonia Williamtown Witchcliffe Wollongong
## 3953 3953 3952 3984
## Woomera
## 3953
Your donation will support ongoing development and give you access to the PDF version of the book. Desktop Survival Guides include Data Science, GNU/Linux, and MLHub. Books available on Amazon include Data Mining with Rattle and Essentials of Data Science. Popular open source software includes rattle, wajig, and mlhub. Hosted by Togaware, a pioneer of free and open source software since 1984.
Copyright © 1995-2021 Graham.Williams@togaware.com Creative Commons Attribution-ShareAlike 4.0.