Purpose: 1) choose the dataset of “Doctors who do not travel”, which was identified by other student in the week5 discussion 2) Read the information from csv file into R 3)this dataset is in a long format (the location of doctors who travel are in their own row), need to be spread into wide format 4) some varibles are not needed, so we get rid of it 5) Do some plots for data visulization
# file name: GH Project2 Doctors Who Do not travel
getwd()
## [1] "D:/Project2 Week6 Due Oct7 GH DataToUse"
setwd('D:/Project2 Week6 Due Oct7 GH DataToUse')
library(tidyr)
## Warning: package 'tidyr' was built under R version 3.3.3
library(dplyr)
## Warning: package 'dplyr' was built under R version 3.3.3
##
## Attaching package: 'dplyr'
## The following objects are masked from 'package:stats':
##
## filter, lag
## The following objects are masked from 'package:base':
##
## intersect, setdiff, setequal, union
library(ggplot2)
library(sqldf)
## Warning: package 'sqldf' was built under R version 3.3.3
## Loading required package: gsubfn
## Warning: package 'gsubfn' was built under R version 3.3.3
## Loading required package: proto
## Warning: package 'proto' was built under R version 3.3.3
## Loading required package: RSQLite
## Warning: package 'RSQLite' was built under R version 3.3.3
library(magrittr)
##
## Attaching package: 'magrittr'
## The following object is masked from 'package:tidyr':
##
## extract
library(DT)
## Warning: package 'DT' was built under R version 3.3.3
dataraw2 <- read.csv ("D:/Project2 Week6 Due Oct7 GH DataToUse/Doctor Who Time Travel Journeys.csv")
print(dataraw2)
## Doctor.Who.season doctor.actor ep..no
## 1 10 Tennant xmas 2006
## 2 1 Hartnell 1
## 3 1 Hartnell 21
## 4 3 Pertwee 64
## 5 1 Hartnell 20
## 6 1 Hartnell 12
## 7 10 Tennant 402
## 8 11 Smith 12
## 9 1 Hartnell 17
## 10 1 Hartnell 14
## 11 3 Pertwee 70
## 12 1 Hartnell 4
## 13 1 Hartnell 6
## 14 1 Hartnell 22
## 15 11 Smith 6
## 16 10 Tennant 302
## 17 5 Davison 119
## 18 1 Hartnell 28
## 19 11 Smith 3
## 20 10 Tennant 204
## 21 2 Troughton 31
## 22 2 Troughton 61
## 23 10 Tennant 204
## 24 10 Tennant 204
## 25 10 Tennant 204
## 26 1 Hartnell 8
## 27 6 Colin Baker 139
## 28 10 Tennant xmas 2008
## 29 9 Eccleston 159
## 30 1 Hartnell 16
## 31 10 Tennant 202
## 32 1 Hartnell 25
## 33 6 Colin Baker 141
## 34 4 Baker 91
## 35 2 Troughton 59
## 36 4 Baker 82
## 37 10 Tennant 308
## 38 1 Hartnell 21
## 39 10 Tennant 310
## 40 5 Davison 120
## 41 2 Troughton 45
## 42 10 Tennant 407
## 43 3 Pertwee 66
## 44 2 Troughton 38
## 45 10 Tennant 304
## 46 11 Smith 8
## 47 Eccleston 164
## 48 11 Smith 3
## 49 11 Smith 12
## 50 7 McCoy 154
## 51 10 Tennant 206
## 52 1 Hartnell 9
## 53 7 McCoy 148
## 54 1 Hartnell 21
## 55 1 Hartnell 27
## 56 2 Troughton 35
## 57 2 Troughton 36
## 58 2 Troughton 42
## 59 Tennant
## 60 11 Smith 1
## 61 11 Smith 13
## 62 2 Troughton 41
## 63 2 Troughton 46
## 64 11 Smith 2
## 65 3 Pertwee 59
## 66 3 Pertwee 64
## 67 3 Pertwee 69
## 68 3 Pertwee 71
## 69 4 Baker 94
## 70 4 Baker 105
## 71 4 Baker unaired
## 72 4 Baker 83
## 73 4 Baker 87
## 74 5 Davison 116
## 75 5 Davison 122
## 76 5 Davison 128
## 77 5 Davison 123
## 78 5 Davison 125
## 79 5 Davison 131
## 80 7 McCoy 153
## 81 5 Davison 133
## 82 1 Hartnell 29
## 83 7 McCoy 155
## 84 9 Eccleston 163
## 85 7 McCoy 150
## 86 3 Pertwee 51
## 87 7 McCoy 152
## 88 1 Hartnell 16
## 89 11 Smith 1
## 90 11 Smith 13
## 91 8 McGann -
## 92 9 Eccleston 157
## 93 9 Eccleston 160
## 94 9 Eccleston 165
## 95 10 Tennant 203
## 96 10 Tennant 205
## 97 10 Tennant 306
## 98 Tennant
## 99 10 Tennant 312
## 100 10 Tennant 313
## 101 10 Tennant 411
## 102 11 Smith 1
## 103 10 Tennant 405
## 104 10 Tennant Special
## 105 10 Tennant Special
## 106 11 Smith 1
## 107 11 Smith 5
## 108 11 Smith 7
## 109 11 Smith 10
## 110 11 Smith 12
## 111 11 Smith 13
## 112 11 Smith 13
## 113 11 Smith Special
## 114 9 Eccleston 161
## 115 10 Tennant 209
## 116 11 Smith 8
## 117 5 Davison 130
## 118 3 Pertwee 60
## 119 11 Smith 5
## 120 11 Smith 6
## 121 7 McCoy 145
## 122 1 Hartnell 10
## 123 2 Troughton 48
## 124 5 Davison 121
## 125 6 Colin Baker 137
## 126 5 Davison 126
## 127 1 Hartnell 19
## 128 7 McCoy 146
## 129 11 Smith 13
## 130 11 Smith 12
## 131 11 Smith 12
## 132 11 Smith Special
## 133 9 Eccleston 158
## 134 10 Tennant 311
## 135 SEASON 1
## episode.title from
## 1 the Runaway Bride 2007
## 2 An Unearthly Child 1963
## 3 The Daleks' Master Plan -2500
## 4 The Time Monster 1972
## 5 The Myth Makers -1200
## 6 The Romans 64
## 7 The Fires of Pompeii 2009
## 8 The Pandorica Opens 5145
## 9 The Time Meddler 1965
## 10 The Crusade 1200
## 11 The Time Warrior 1973
## 12 Marco Polo -13,000,000,000
## 13 The Aztecs 1454
## 14 The Massacre of St Bartholomew's Eve 1572
## 15 The Vampires of Venice 2010
## 16 The Shakespeare Code 2008
## 17 The Visitation 1666
## 18 The Smugglers 1671
## 19 The Curse of the Black Spot 1699
## 20 the Girl in the Fireplace 1727
## 21 The Highlanders 1746
## 22 The War Games 1969
## 23 the Girl in the Fireplace 1744
## 24 the Girl in the Fireplace 1753
## 25 the Girl in the Fireplace 1758
## 26 The Reign of Terror 2700
## 27 The Mark of the Rani 1822
## 28 the next Doctor 2008
## 29 The Unquiet Dead 1869
## 30 The Chase 1966
## 31 Tooth and claw 2006
## 32 The Gunfighters 1881
## 33 Timelash 1885
## 34 The Talons of Weng-Chiang 1889
## 35 The War Games 1969
## 36 Pyramids of Mars 1911
## 37 Human Nature 1913
## 38 The Daleks' Master Plan 1920
## 39 Blink 2007
## 40 Black Orchid 1925
## 41 The Mind Robber 1968
## 42 The Unicorn and the Wasp 1926
## 43 Carnival of Monsters 1972
## 44 The Abominable Snowmen 1930
## 45 Daleks in Manhattan 1930
## 46 Let's Kill Hitler 5100
## 47 The Empty Child 2005
## 48 Victory of the Daleks 1941
## 49 The Pandorica Opens 1890
## 50 The Curse of Fenric 1943
## 51 The Idiot's Lantern 1953
## 52 Planet of The Giants 1794
## 53 Remembrance of the Daleks 1963
## 54 The Daleks' Master Plan 4000
## 55 The War Machines 1966
## 56 The Faceless Ones 1966
## 57 The Evil Of The Daleks 1866
## 58 Fury From The Deep 1967
## 59 2007
## 60 The Impossible Astronaut 2011
## 61 The Wedding of River Song 5100
## 62 The Web Of Fear 1970
## 63 The Invasion 2000
## 64 Day of the Moon 1969
## 65 The Daemons 1971
## 66 The Time Monster -2000
## 67 The Green Death 2540
## 68 Invasion of The Dinosaurs 1200
## 69 Image of the Fendahl 1977
## 70 City of Death -4.00E+12
## 71 Shada 1979
## 72 The Android Invasion 1980
## 73 The Hand of Fear 1980
## 74 Castrovalva -13700000000
## 75 Time-Flight -140000000
## 76 The King's Demons 1214
## 77 Arc of Infinity 1978
## 78 Mawdryn Undead -1017
## 79 The Awakening 1643
## 80 Ghost Light 1883
## 81 Resurrection of the Daleks 1984
## 82 The Tenth Planet 1986
## 83 Survival 1987
## 84 Fathers Day 2005
## 85 Silver Nemesis 1606
## 86 Spearhead from Space 1970
## 87 Battlefield 793
## 88 The Chase 1872
## 89 The Eleventh Hour 1999
## 90 The Big Bang 2010
## 91 Doctor Who 1999
## 92 Rose 1883
## 93 Aliens Of London 2006
## 94 Boom Town 2005
## 95 school Reunion 2007
## 96 Rise of the Cybermen 2007
## 97 The Lazarus Experiment 2008
## 98 2007
## 99 The Sound of Drums 100,000,000,000,000
## 100 Last of the Time Lords 2009
## 101 Turn Left 2007
## 102 The Eleventh Hour 1996
## 103 The Poison Sky 2009
## 104 Planet of the Dead 2009
## 105 The End of Time - Part 2 2009
## 106 The Eleventh Hour 2008
## 107 Flesh and Stone 5000
## 108 Amy's Choice 2015
## 109 Vincent and the Doctor 1890
## 110 The Pandorica Opens 102
## 111 The Big Bang 102
## 112 The Big Bang 1996
## 113 A Christmas Carol 4300
## 114 Dalek 2012
## 115 Fear her 2012
## 116 The Hungry Earth 2020
## 117 Warriors of the Deep 2084
## 118 Day of the Daleks 1972
## 119 The Rebel Flesh 2100
## 120 The Almost People 2100
## 121 Paradise Towers 2110
## 122 The Dalek Invasion of Earth 1963
## 123 The Seeds Of Death 1970
## 124 Earthshock 2486
## 125 Attack of the Cybermen 1985
## 126 Terminus -13700000000
## 127 Mission to the Unknown 3999
## 128 Delta and the Bannermen 1928
## 129 The Big Bang 2010
## 130 Closing Time 2011
## 131 The Pandorica Opens 1941
## 132 The Doctor, the Widow and the Wardrobe 1938
## 133 The End Of The World 2005
## 134 Utopia 2008
## 135
## estimated.from to estimated.
## 1 NA -5000000000
## 2 NA -100000
## 3 4000 -2500
## 4 2900 -2000
## 5 3999 -1200 y
## 6 2493 64
## 7 NA 79
## 8 NA 102
## 9 NA 1066
## 10 1965 1200
## 11 NA 1200 n
## 12 NA 1289
## 13 1289 1454
## 14 4000 1572
## 15 NA 1580
## 16 NA 1599
## 17 2583 1666
## 18 1966 1671 n (see notes)
## 19 1970 1699
## 20 NA 1744
## 21 1986 1746 n
## 22 NA 1746 n
## 23 NA 1753
## 24 NA 1758
## 25 NA 1764
## 26 NA 1794
## 27 NA 1822
## 28 NA 1851
## 29 5000000000 1869
## 30 NA 1872
## 31 NA 1879
## 32 10000700 1881
## 33 1985 1885
## 34 1980 1889
## 35 NA 1900 n
## 36 37166 1911
## 37 2008 1913
## 38 1965 1920
## 39 NA 1920
## 40 1666 1925
## 41 NA 1926
## 42 2009 1926
## 43 NA 1928 n
## 44 1966 1930 y
## 45 5000000053 1930
## 46 NA 1938
## 47 NA 1941
## 48 3295 1941
## 49 NA 1941
## 50 1983 1943
## 51 2007 1953
## 52 NA 1963
## 53 4687 1963
## 54 NA 1965
## 55 1881 1966
## 56 2070 1966 y
## 57 NA 1966 y
## 58 1970 1967 y
## 59 NA 1969
## 60 NA 1969 y
## 61 NA 1969 y
## 62 1930 1970 y
## 63 NA 1970 y
## 64 NA 1970
## 65 2472 1971 y
## 66 NA 1972
## 67 NA 1973 y
## 68 NA 1974 y
## 69 5000 1977
## 70 NA 1979
## 71 2116 1979
## 72 1911 1980
## 73 1492 1980 y
## 74 NA 1981
## 75 NA 1982
## 76 NA 1982
## 77 NA 1983
## 78 NA 1983
## 79 NA 1983
## 80 NA 1983
## 81 10000000 1984
## 82 1671 1986 n
## 83 1943 1987
## 84 NA 1987
## 85 NA 1988
## 86 NA 1990 y
## 87 NA 1993
## 88 NA 1996
## 89 NA 1996
## 90 NA 1996
## 91 1987 1999
## 92 NA 2005
## 93 1869 2006
## 94 NA 2006
## 95 1879 2007
## 96 1764 2007
## 97 1930 2008
## 98 NA 2008
## 99 NA 2008
## 100 NA 2008
## 101 2700 2008
## 102 NA 2008
## 103 4126 2009
## 104 1851 2009
## 105 NA 2010
## 106 NA 2010
## 107 NA 2010 y
## 108 NA 2010
## 109 NA 2010
## 110 NA 2010
## 111 NA 2010
## 112 NA 2010
## 113 NA 2011 y
## 114 2006 2012
## 115 NA 2012
## 116 2010 2020
## 117 1982 2084
## 118 NA 2100
## 119 NA 2100 y
## 120 NA 2100 y
## 121 1987 2110
## 122 NA 2164
## 123 NA 2190 y
## 124 NA 2526
## 125 NA 2530
## 126 NA 2683
## 127 1066 3999 y
## 128 NA 4687
## 129 NA 5000 y
## 130 NA 5100 y
## 131 NA 5145
## 132 NA 5345
## 133 NA 5000000000
## 134 NA 100,000,000,000,000
## 135 NA
## planet sub.location
## 1 Earth England
## 2 n/a
## 3 Earth
## 4 Earth/ Atlantis
## 5 Earth
## 6 Earth Italy
## 7 Earth Roman Empire
## 8 Earth England
## 9 UK
## 10 Earth
## 11 Earth UK
## 12 Earth China
## 13 Earth Mexico
## 14 Earth France
## 15 Earth
## 16 Earth England
## 17 Earth England
## 18 Earth UK
## 19 Earth Earth and a parallel Earth
## 20 Earth France
## 21 Earth UK
## 22 Earth Scotland
## 23 Earth France
## 24 Earth France
## 25 Earth France
## 26 Earth France
## 27 earth England
## 28 Earth
## 29 Earth England
## 30 Earth
## 31 Earth Scotland
## 32 Earth USA
## 33 earth England
## 34 Earth England
## 35 Earth
## 36 Earth England
## 37 Earth England
## 38 Earth USA
## 39 Earth England
## 40 Earth England
## 41
## 42 Earth Yorkshire
## 43 Indian Ocean, Planet Inter Minor Ocean, alien planet
## 44 Earth
## 45 Earth USA
## 46 Earth Berlin
## 47 Earth England
## 48 Earth England
## 49 Earth
## 50 Earth England
## 51 Earth England
## 52 Earth
## 53 Earth England
## 54 Earth UK
## 55 Earth UK
## 56 Earth UK\n
## 57 Earth UK
## 58 Earth UK
## 59 Earth England
## 60 Earth England and USA
## 61 Earth Utah
## 62 Earth UK
## 63 Earth UK
## 64 Earth USA
## 65 Earth England
## 66 Earth/ Atlantis
## 67 Earth UK
## 68 Earth UK
## 69 Earth England
## 70 Earth France; Italy
## 71 Earth England
## 72 Planet: Oseidon; also village of Devesham England
## 73 Earth England
## 74 ????
## 75 Earth England
## 76 earth
## 77 Gallifrey, Earth
## 78 earth England
## 79 earth England
## 80 Earth England
## 81 earth England
## 82 Earth
## 83 Earth England
## 84 Earth England
## 85 Earth England
## 86 Earth England
## 87 Earth England
## 88 Earth Africa
## 89 Earth England
## 90 Earth England
## 91 Earth USA
## 92 Earth England
## 93 Earth England
## 94 Earth England
## 95 Earth England
## 96 Earth England
## 97 Earth England
## 98 Earth England
## 99 Earth England
## 100 Earth England
## 101 Earth
## 102 Earth England
## 103 Earth England
## 104 Earth
## 105 Earth
## 106 Earth England
## 107 Dundra System to Earth
## 108 Earth
## 109 Earth France
## 110 Earth England and Planet One
## 111 Earth England
## 112 Earth England
## 113 Earth USA
## 114 Earth USA
## 115 Earth England
## 116 Earth UK
## 117 earth
## 118 Earth England
## 119 Earth n/a
## 120 Earth n/a
## 121 Earth
## 122 Earth UK
## 123 Earth UK
## 124 Earth
## 125 earth England
## 126 earth
## 127 Earth
## 128 Earth England
## 129
## 130 Earth
## 131 Earth and other planets
## 132 Earth England
## 133 space
## 134 Earth England
## 135
## location
## 1 London
## 2 n/a
## 3 Egypt
## 4
## 5 Asia Minor/Troy
## 6 Rome
## 7 Pompeii
## 8 to Stonehenge
## 9 Northumbria
## 10 Palestine
## 11 Wessex Castle
## 12 multiple
## 13
## 14 Paris
## 15 Leadworth to Venice
## 16 London
## 17 London
## 18 Cornwall
## 19 The Fancy (Ship)
## 20 Paris
## 21 Culloden
## 22 battle of Culloden
## 23 Versailles
## 24 Versailles
## 25 Versailles
## 26 Paris
## 27 Killingworth
## 28 London
## 29 Cardiff
## 30 Atlantic Ocean
## 31 Torchwood house, Near Balmoral
## 32 tombstone, arizona
## 33 Scotland
## 34 London
## 35
## 36 The site of UNIT HQ, years before it was built. Currently, a priory.
## 37 Farringham
## 38 Hollywood
## 39 Hull
## 40 Cranleigh Halt
## 41 "the land of fiction"
## 42 Harrogate
## 43
## 44 Tibet
## 45 Manhattan, New York
## 46 Germany
## 47 London
## 48 London
## 49 France to London
## 50 Maiden's Point, Northumberland
## 51 London
## 52
## 53 London
## 54 Liverpool
## 55 London
## 56 Gatwick Airport\nEarth orbit
## 57 London\nSkaro
## 58 North Sea
## 59 London
## 60 London to Utah
## 61 Amercia
## 62 London
## 63 Just outside London
## 64 Utah to Cape Kennedy
## 65 Devil's End, Wiltshire
## 66
## 67 Llanfairfach, Wales
## 68 London
## 69 Fetch Priory
## 70 Paris; Italy
## 71 Cambridge
## 72
## 73 Planet: Kastria;
## 74 City of Castrovalva
## 75 Heathrow
## 76 England
## 77
## 78 Brendon, London
## 79 Little Hodcombe
## 80 Gabriel's Chase, Perivale
## 81 London
## 82 South Pole
## 83 Perivale
## 84 London
## 85
## 86 London and other
## 87 Lake Vortigern
## 88 Ghana
## 89 London
## 90 National Museum, London
## 91 San Francisco
## 92 London
## 93 London
## 94 Cardiff
## 95 Deffry Vale
## 96 London (Parallel)
## 97 London
## 98 London
## 99 Malcassairo and London
## 100 Alternative England and London
## 101 London
## 102 Leadworth
## 103 London
## 104 San Helios, London
## 105 London
## 106 Leadworth
## 107 Alfava Metraxis to Leadworth
## 108 Leadworth
## 109 Auvers-sur-Oise to Paris
## 110 Stonehenge to Leadworth and Planet One
## 111 Stonehenge to Leadworth
## 112 Aickman Road, Colchester
## 113
## 114 Utah
## 115 London
## 116 Cwmtaff, Wales
## 117
## 118 Auderly House and environs
## 119 n/a
## 120 n/a
## 121
## 122 London
## 123 space museum, London; the moon
## 124
## 125 London
## 126 Terminus Station
## 127 Kembel
## 128 South Wales
## 129 The Byzantium
## 130
## 131 London to Stormcage Containment Facility, The Royal Collection and The Maldovarium
## 132
## 133 Earth orbit
## 134 Cardiff and Malcassairo
## 135
## notes
## 1
## 2
## 3
## 4 'ancient' Atlantis. Krasis is brought forward in time from 2000 BC
## 5
## 6
## 7
## 8
## 9
## 10 "12th century"
## 11 "13th century"
## 12
## 13
## 14
## 15
## 16
## 17
## 18 Dr dialogue says 17th century, and Blake was a 'revenue man', i.e. an officer of the Board of Customs created in 1671.
## 19
## 20
## 21
## 22 ONLY JAMIE sent home by time lords
## 23
## 24
## 25
## 26
## 27
## 28 dvd : doctor speaks to young boy
## 29 poster on wall - dvd at 06:41
## 30
## 31
## 32
## 33
## 34
## 35 ONLY THE DR sentanced to exile on earth in the 20th century
## 36 Brief visits to 1987 (alternate earth) and Mars. Year stated in episode 1, at approximately the 18:00 mark.
## 37
## 38 "1920s"
## 39 Part of this ep is in 1969.
## 40
## 41 The Dr goes into 'An endless void'
## 42
## 43 Actually inside a simulation of 1928. 1970s\n
## 44 early 1930s (same time, no trips)
## 45
## 46
## 47
## 48
## 49
## 50
## 51
## 52
## 53
## 54 dec25th 1965
## 55
## 56
## 57
## 58 The story takes place when North Sea gas is being supplied to England, which commenced in 1967, but before decimalisation in the UK
## 59
## 60
## 61
## 62 early 1970s (same time, no trips)\n40 years after Abominable Snowmen
## 63 21st century - 1070s
## 64
## 65
## 66
## 67
## 68
## 69
## 70 Wikia notes multiple jumps -- 1979; 1505; 1979; 4 billion BC; 1979
## 71
## 72
## 73
## 74
## 75
## 76
## 77
## 78
## 79
## 80
## 81
## 82
## 83
## 84
## 85
## 86 late 20th Century
## 87
## 88
## 89
## 90
## 91 New Year's Eve
## 92
## 93
## 94
## 95
## 96
## 97 morning after ep 301
## 98
## 99
## 100 *the ep partially takes place in 2009, but this timeline ends up being "reset"
## 101 added from date, Runaway Bride
## 102
## 103
## 104
## 105
## 106
## 107
## 108
## 109
## 110
## 111
## 112
## 113
## 114 the doctor - dvd at aprox 00:30
## 115 27th July for the torch lighting, if you want dates - ms
## 116
## 117
## 118
## 119
## 120
## 121
## 122
## 123 late 21st century'
## 124
## 125
## 126
## 127
## 128
## 129
## 130
## 131
## 132
## 133
## 134
## 135
## source
## 1 http://who-transcripts.atspace.com/
## 2 http://tardis.wikia.com/wiki/An_Unearthly_Child
## 3 http://tardis.wikia.com/wiki/Season_Three
## 4 http://tardis.wikia.com/wiki/Krasis
## 5 http://tardis.wikia.com/wiki/Season_Three
## 6 http://tardis.wikia.com/wiki/Season_Two
## 7
## 8 http://tardis.wikia.com/wiki/The_Pandorica_Opens_%28TV_story%29
## 9 http://tardis.wikia.com/wiki/Season_Two
## 10 http://tardis.wikia.com/wiki/Season_Two
## 11 http://tardis.wikia.com/wiki/The_Time_Warrior
## 12 http://tardis.wikia.com/wiki/An_Unearthly_Child
## 13 http://tardis.wikia.com/wiki/An_Unearthly_Child
## 14 http://tardis.wikia.com/wiki/Season_Three
## 15 http://tardis.wikia.com/wiki/The_Vampires_of_Venice
## 16 http://who-transcripts.atspace.com/
## 17
## 18 http://tardis.wikia.com/wiki/The_Smugglers\nhttp://en.wikipedia.org/wiki/Chronology_of_the_Doctor_Who_universe
## 19
## 20 tardis.wikia.com
## 21 http://tardis.wikia.com/wiki/The_Highlanders
## 22 http://tardis.wikia.com/wiki/Jamie
## 23 tardis.wikia.com
## 24 tardis.wikia.com
## 25 tardis.wikia.com
## 26 http://tardis.wikia.com/wiki/An_Unearthly_Child
## 27
## 28
## 29
## 30
## 31 http://who-transcripts.atspace.com/
## 32 http://tardis.wikia.com/wiki/Season_Three
## 33
## 34 Doctor Who Wikia
## 35 http://tardis.wikia.com/wiki/The_War_Games
## 36
## 37 http://who-transcripts.atspace.com/
## 38 http://tardis.wikia.com/wiki/Season_Three
## 39 http://tardis.wikia.com/wiki/Blink\nhttp://who-transcripts.atspace.com/2007/transcripts/310_blink.html
## 40
## 41 http://tardis.wikia.com/wiki/The_Mind_Robber
## 42
## 43 http://tardis.wikia.com/wiki/Carnival_of_Monsters
## 44 http://tardis.wikia.com/wiki/The_Abominable_Snowmen
## 45 http://who-transcripts.atspace.com/
## 46
## 47
## 48 http://tardis.wikia.com/wiki/Victory_of_the_Daleks
## 49 http://tardis.wikia.com/wiki/The_Pandorica_Opens_%28TV_story%29
## 50
## 51 dvd - "eve of the coronation"
## 52
## 53
## 54 http://tardis.wikia.com/wiki/Season_Three
## 55 http://tardis.wikia.com/wiki/Season_Three
## 56 http://tardis.wikia.com/wiki/The_Faceless_Ones
## 57 http://tardis.wikia.com/wiki/The_Evil_of_the_Daleks
## 58 http://tardis.wikia.com/wiki/Fury_from_the_Deep\nhttp://en.wikipedia.org/wiki/Chronology_of_the_Doctor_Who_universe
## 59
## 60
## 61
## 62 http://tardis.wikia.com/wiki/The_Web_of_Fear\nhttp://en.wikipedia.org/wiki/Chronology_of_the_Doctor_Who_universe
## 63 http://tardis.wikia.com/wiki/The_Invasion
## 64
## 65 http://tardis.wikia.com/wiki/Season_8
## 66 http://tardis.wikia.com/wiki/Krasis
## 67 http://tardis.wikia.com/wiki/The_Green_Death
## 68 http://tardis.wikia.com/wiki/Invasion_of_the_Dinosaurs
## 69 Doctor Who Wikia
## 70 Doctor Who Wikia
## 71 Doctor Who Wikia
## 72 Doctor Who wikia, tardis.wikia.com/wiki/The_Android_invasion
## 73 Doctor Who Wikia
## 74
## 75
## 76
## 77
## 78
## 79
## 80
## 81
## 82 http://tardis.wikia.com/wiki/The_Tenth_Planet
## 83
## 84 tardis.wikia
## 85
## 86
## 87
## 88
## 89 http://tardis.wikia.com/wiki/The_Eleventh_Hour
## 90 http://tardis.wikia.com/wiki/The_Big_Bang
## 91
## 92
## 93
## 94 tardis.wikia
## 95 http://who-transcripts.atspace.com/
## 96 http://who-transcripts.atspace.com/
## 97 http://who-transcripts.atspace.com/
## 98
## 99
## 100
## 101
## 102 http://tardis.wikia.com/wiki/The_Eleventh_Hour
## 103
## 104
## 105 http://tardis.wikia.com/wiki/The_End_of_Time_(TV_story)
## 106 http://tardis.wikia.com/wiki/The_Eleventh_Hour
## 107 http://tardis.wikia.com/wiki/Flesh_and_Stone
## 108 http://tardis.wikia.com/wiki/Amy%27s_Choice
## 109 http://tardis.wikia.com/wiki/Vincent_and_the_Doctor
## 110 http://tardis.wikia.com/wiki/The_Pandorica_Opens_%28TV_story%29
## 111 http://tardis.wikia.com/wiki/The_Big_Bang
## 112 http://tardis.wikia.com/wiki/The_Big_Bang
## 113
## 114
## 115 http://who-transcripts.atspace.com/
## 116 http://tardis.wikia.com/wiki/The_Hungry_Earth
## 117
## 118 http://tardis.wikia.com/wiki/Season_9
## 119
## 120
## 121
## 122
## 123 http://tardis.wikia.com/wiki/The_Seeds_of_Death
## 124
## 125
## 126
## 127 http://tardis.wikia.com/wiki/Season_Three
## 128
## 129 http://tardis.wikia.com/wiki/The_Big_Bang
## 130
## 131 http://tardis.wikia.com/wiki/The_Pandorica_Opens_%28TV_story%29
## 132
## 133
## 134 http://who-transcripts.atspace.com/
## 135
## X
## 1
## 2
## 3
## 4
## 5
## 6
## 7
## 8
## 9
## 10
## 11
## 12
## 13
## 14
## 15
## 16
## 17
## 18
## 19
## 20
## 21
## 22
## 23
## 24
## 25
## 26
## 27
## 28
## 29
## 30
## 31
## 32
## 33
## 34
## 35
## 36 Soutek is sent to "a thousand years beyond the 20th century," but the TARDIS doesn't go there. Does that count?
## 37
## 38
## 39
## 40
## 41
## 42
## 43
## 44
## 45
## 46
## 47
## 48
## 49
## 50
## 51
## 52
## 53
## 54
## 55
## 56
## 57
## 58
## 59
## 60
## 61
## 62
## 63
## 64
## 65
## 66
## 67
## 68
## 69
## 70
## 71
## 72
## 73
## 74
## 75
## 76
## 77
## 78
## 79
## 80
## 81
## 82
## 83
## 84
## 85
## 86
## 87
## 88
## 89
## 90
## 91
## 92
## 93
## 94
## 95
## 96
## 97
## 98
## 99
## 100
## 101
## 102
## 103
## 104
## 105
## 106
## 107
## 108
## 109
## 110
## 111
## 112
## 113
## 114
## 115
## 116
## 117
## 118
## 119
## 120
## 121
## 122
## 123
## 124
## 125
## 126
## 127
## 128
## 129
## 130
## 131
## 132
## 133
## 134
## 135
## X.1 X.2 X.3 X.4 X.5 X.6
## 1 NA NA NA NA NA
## 2 NA NA NA NA NA
## 3 NA NA NA NA NA
## 4 NA NA NA NA NA
## 5 NA NA NA NA NA
## 6 NA NA NA NA NA
## 7 NA NA NA NA NA
## 8 NA NA NA NA NA
## 9 NA NA NA NA NA
## 10 NA NA NA NA NA
## 11 NA NA NA NA NA
## 12 NA NA NA NA NA
## 13 NA NA NA NA NA
## 14 NA NA NA NA NA
## 15 NA NA NA NA NA
## 16 NA NA NA NA NA
## 17 NA NA NA NA NA
## 18 NA NA NA NA NA
## 19 NA NA NA NA NA
## 20 NA NA NA NA NA
## 21 NA NA NA NA NA
## 22 NA NA NA NA NA
## 23 NA NA NA NA NA
## 24 NA NA NA NA NA
## 25 NA NA NA NA NA
## 26 NA NA NA NA NA
## 27 NA NA NA NA NA
## 28 NA NA NA NA NA
## 29 NA NA NA NA NA
## 30 NA NA NA NA NA
## 31 NA NA NA NA NA
## 32 NA NA NA NA NA
## 33 NA NA NA NA NA
## 34 NA NA NA NA NA
## 35 NA NA NA NA NA
## 36 no, only TARDIS journeys - DM NA NA NA NA NA
## 37 NA NA NA NA NA
## 38 NA NA NA NA NA
## 39 NA NA NA NA NA
## 40 NA NA NA NA NA
## 41 NA NA NA NA NA
## 42 NA NA NA NA NA
## 43 NA NA NA NA NA
## 44 NA NA NA NA NA
## 45 NA NA NA NA NA
## 46 NA NA NA NA NA
## 47 NA NA NA NA NA
## 48 NA NA NA NA NA
## 49 NA NA NA NA NA
## 50 NA NA NA NA NA
## 51 NA NA NA NA NA
## 52 NA NA NA NA NA
## 53 NA NA NA NA NA
## 54 NA NA NA NA NA
## 55 NA NA NA NA NA
## 56 NA NA NA NA NA
## 57 NA NA NA NA NA
## 58 NA NA NA NA NA
## 59 NA NA NA NA NA
## 60 NA NA NA NA NA
## 61 NA NA NA NA NA
## 62 NA NA NA NA NA
## 63 NA NA NA NA NA
## 64 NA NA NA NA NA
## 65 NA NA NA NA NA
## 66 NA NA NA NA NA
## 67 NA NA NA NA NA
## 68 NA NA NA NA NA
## 69 NA NA NA NA NA
## 70 NA NA NA NA NA
## 71 NA NA NA NA NA
## 72 NA NA NA NA NA
## 73 NA NA NA NA NA
## 74 NA NA NA NA NA
## 75 NA NA NA NA NA
## 76 NA NA NA NA NA
## 77 NA NA NA NA NA
## 78 NA NA NA NA NA
## 79 NA NA NA NA NA
## 80 NA NA NA NA NA
## 81 NA NA NA NA NA
## 82 NA NA NA NA NA
## 83 NA NA NA NA NA
## 84 NA NA NA NA NA
## 85 NA NA NA NA NA
## 86 NA NA NA NA NA
## 87 NA NA NA NA NA
## 88 NA NA NA NA NA
## 89 NA NA NA NA NA
## 90 NA NA NA NA NA
## 91 NA NA NA NA NA
## 92 NA NA NA NA NA
## 93 NA NA NA NA NA
## 94 NA NA NA NA NA
## 95 NA NA NA NA NA
## 96 NA NA NA NA NA
## 97 NA NA NA NA NA
## 98 NA NA NA NA NA
## 99 NA NA NA NA NA
## 100 NA NA NA NA NA
## 101 NA NA NA NA NA
## 102 NA NA NA NA NA
## 103 NA NA NA NA NA
## 104 NA NA NA NA NA
## 105 NA NA NA NA NA
## 106 NA NA NA NA NA
## 107 NA NA NA NA NA
## 108 NA NA NA NA NA
## 109 NA NA NA NA NA
## 110 NA NA NA NA NA
## 111 NA NA NA NA NA
## 112 NA NA NA NA NA
## 113 NA NA NA NA NA
## 114 NA NA NA NA NA
## 115 NA NA NA NA NA
## 116 NA NA NA NA NA
## 117 NA NA NA NA NA
## 118 NA NA NA NA NA
## 119 NA NA NA NA NA
## 120 NA NA NA NA NA
## 121 NA NA NA NA NA
## 122 NA NA NA NA NA
## 123 NA NA NA NA NA
## 124 NA NA NA NA NA
## 125 NA NA NA NA NA
## 126 NA NA NA NA NA
## 127 NA NA NA NA NA
## 128 NA NA NA NA NA
## 129 NA NA NA NA NA
## 130 NA NA NA NA NA
## 131 NA NA NA NA NA
## 132 NA NA NA NA NA
## 133 NA NA NA NA NA
## 134 NA NA NA NA NA
## 135 NA NA NA NA NA
to select only the needed column, to get rid of the columnn not needed,
Data11 <- dataraw2 %>%
select (c (Doctor.Who.season, doctor.actor,ep..no,from,estimated.from,
planet,sub.location, location)
)
summary (Data11)
## Doctor.Who.season doctor.actor ep..no from
## 11 :27 Smith :27 12 : 6 2007 : 7
## 10 :25 Tennant :27 1 : 5 2008 : 5
## 1 :21 Hartnell :21 13 : 5 2009 : 5
## 5 :12 Davison :12 204 : 4 2005 : 4
## 2 :11 Troughton:11 Special: 4 1963 : 3
## 3 : 9 Pertwee : 9 : 3 1966 : 3
## (Other):30 (Other) :28 (Other):108 (Other):108
## estimated.from planet sub.location
## Min. :1.066e+03 Earth :112 England:55
## 1st Qu.:1.936e+03 earth : 9 :32
## Median :1.987e+03 : 5 UK :15
## Mean :1.965e+08 Earth/ Atlantis : 2 France : 7
## 3rd Qu.:2.800e+03 ???? : 1 USA : 7
## Max. :5.000e+09 Dundra System to Earth: 1 n/a : 3
## NA's :84 (Other) : 5 (Other):16
## location
## London :24
## :16
## Leadworth : 3
## n/a : 3
## Paris : 3
## Versailles: 3
## (Other) :83
head(Data11)
## Doctor.Who.season doctor.actor ep..no from estimated.from
## 1 10 Tennant xmas 2006 2007 NA
## 2 1 Hartnell 1 1963 NA
## 3 1 Hartnell 21 -2500 4000
## 4 3 Pertwee 64 1972 2900
## 5 1 Hartnell 20 -1200 3999
## 6 1 Hartnell 12 64 2493
## planet sub.location location
## 1 Earth England London
## 2 n/a n/a
## 3 Earth Egypt
## 4 Earth/ Atlantis
## 5 Earth Asia Minor/Troy
## 6 Earth Italy Rome
tail(Data11)
## Doctor.Who.season doctor.actor ep..no from estimated.from
## 130 11 Smith 12 2011 NA
## 131 11 Smith 12 1941 NA
## 132 11 Smith Special 1938 NA
## 133 9 Eccleston 158 2005 NA
## 134 10 Tennant 311 2008 NA
## 135 SEASON 1 NA
## planet sub.location
## 130 Earth
## 131 Earth and other planets
## 132 Earth England
## 133 space
## 134 Earth England
## 135
## location
## 130
## 131 London to Stormcage Containment Facility, The Royal Collection and The Maldovarium
## 132
## 133 Earth orbit
## 134 Cardiff and Malcassairo
## 135
# get rid of row 98, because it is exactly the same as row 59, which causes problem in the spread function downstream
#Error: Duplicate identifiers for rows (59, 98), this error was fixed in the earlier block, otherwise this block will not run
Data31 <- Data11 [-98,]
print (Data31)
## Doctor.Who.season doctor.actor ep..no from
## 1 10 Tennant xmas 2006 2007
## 2 1 Hartnell 1 1963
## 3 1 Hartnell 21 -2500
## 4 3 Pertwee 64 1972
## 5 1 Hartnell 20 -1200
## 6 1 Hartnell 12 64
## 7 10 Tennant 402 2009
## 8 11 Smith 12 5145
## 9 1 Hartnell 17 1965
## 10 1 Hartnell 14 1200
## 11 3 Pertwee 70 1973
## 12 1 Hartnell 4 -13,000,000,000
## 13 1 Hartnell 6 1454
## 14 1 Hartnell 22 1572
## 15 11 Smith 6 2010
## 16 10 Tennant 302 2008
## 17 5 Davison 119 1666
## 18 1 Hartnell 28 1671
## 19 11 Smith 3 1699
## 20 10 Tennant 204 1727
## 21 2 Troughton 31 1746
## 22 2 Troughton 61 1969
## 23 10 Tennant 204 1744
## 24 10 Tennant 204 1753
## 25 10 Tennant 204 1758
## 26 1 Hartnell 8 2700
## 27 6 Colin Baker 139 1822
## 28 10 Tennant xmas 2008 2008
## 29 9 Eccleston 159 1869
## 30 1 Hartnell 16 1966
## 31 10 Tennant 202 2006
## 32 1 Hartnell 25 1881
## 33 6 Colin Baker 141 1885
## 34 4 Baker 91 1889
## 35 2 Troughton 59 1969
## 36 4 Baker 82 1911
## 37 10 Tennant 308 1913
## 38 1 Hartnell 21 1920
## 39 10 Tennant 310 2007
## 40 5 Davison 120 1925
## 41 2 Troughton 45 1968
## 42 10 Tennant 407 1926
## 43 3 Pertwee 66 1972
## 44 2 Troughton 38 1930
## 45 10 Tennant 304 1930
## 46 11 Smith 8 5100
## 47 Eccleston 164 2005
## 48 11 Smith 3 1941
## 49 11 Smith 12 1890
## 50 7 McCoy 154 1943
## 51 10 Tennant 206 1953
## 52 1 Hartnell 9 1794
## 53 7 McCoy 148 1963
## 54 1 Hartnell 21 4000
## 55 1 Hartnell 27 1966
## 56 2 Troughton 35 1966
## 57 2 Troughton 36 1866
## 58 2 Troughton 42 1967
## 59 Tennant 2007
## 60 11 Smith 1 2011
## 61 11 Smith 13 5100
## 62 2 Troughton 41 1970
## 63 2 Troughton 46 2000
## 64 11 Smith 2 1969
## 65 3 Pertwee 59 1971
## 66 3 Pertwee 64 -2000
## 67 3 Pertwee 69 2540
## 68 3 Pertwee 71 1200
## 69 4 Baker 94 1977
## 70 4 Baker 105 -4.00E+12
## 71 4 Baker unaired 1979
## 72 4 Baker 83 1980
## 73 4 Baker 87 1980
## 74 5 Davison 116 -13700000000
## 75 5 Davison 122 -140000000
## 76 5 Davison 128 1214
## 77 5 Davison 123 1978
## 78 5 Davison 125 -1017
## 79 5 Davison 131 1643
## 80 7 McCoy 153 1883
## 81 5 Davison 133 1984
## 82 1 Hartnell 29 1986
## 83 7 McCoy 155 1987
## 84 9 Eccleston 163 2005
## 85 7 McCoy 150 1606
## 86 3 Pertwee 51 1970
## 87 7 McCoy 152 793
## 88 1 Hartnell 16 1872
## 89 11 Smith 1 1999
## 90 11 Smith 13 2010
## 91 8 McGann - 1999
## 92 9 Eccleston 157 1883
## 93 9 Eccleston 160 2006
## 94 9 Eccleston 165 2005
## 95 10 Tennant 203 2007
## 96 10 Tennant 205 2007
## 97 10 Tennant 306 2008
## 99 10 Tennant 312 100,000,000,000,000
## 100 10 Tennant 313 2009
## 101 10 Tennant 411 2007
## 102 11 Smith 1 1996
## 103 10 Tennant 405 2009
## 104 10 Tennant Special 2009
## 105 10 Tennant Special 2009
## 106 11 Smith 1 2008
## 107 11 Smith 5 5000
## 108 11 Smith 7 2015
## 109 11 Smith 10 1890
## 110 11 Smith 12 102
## 111 11 Smith 13 102
## 112 11 Smith 13 1996
## 113 11 Smith Special 4300
## 114 9 Eccleston 161 2012
## 115 10 Tennant 209 2012
## 116 11 Smith 8 2020
## 117 5 Davison 130 2084
## 118 3 Pertwee 60 1972
## 119 11 Smith 5 2100
## 120 11 Smith 6 2100
## 121 7 McCoy 145 2110
## 122 1 Hartnell 10 1963
## 123 2 Troughton 48 1970
## 124 5 Davison 121 2486
## 125 6 Colin Baker 137 1985
## 126 5 Davison 126 -13700000000
## 127 1 Hartnell 19 3999
## 128 7 McCoy 146 1928
## 129 11 Smith 13 2010
## 130 11 Smith 12 2011
## 131 11 Smith 12 1941
## 132 11 Smith Special 1938
## 133 9 Eccleston 158 2005
## 134 10 Tennant 311 2008
## 135 SEASON 1
## estimated.from planet
## 1 NA Earth
## 2 NA
## 3 4000 Earth
## 4 2900 Earth/ Atlantis
## 5 3999 Earth
## 6 2493 Earth
## 7 NA Earth
## 8 NA Earth
## 9 NA
## 10 1965 Earth
## 11 NA Earth
## 12 NA Earth
## 13 1289 Earth
## 14 4000 Earth
## 15 NA Earth
## 16 NA Earth
## 17 2583 Earth
## 18 1966 Earth
## 19 1970 Earth
## 20 NA Earth
## 21 1986 Earth
## 22 NA Earth
## 23 NA Earth
## 24 NA Earth
## 25 NA Earth
## 26 NA Earth
## 27 NA earth
## 28 NA Earth
## 29 5000000000 Earth
## 30 NA Earth
## 31 NA Earth
## 32 10000700 Earth
## 33 1985 earth
## 34 1980 Earth
## 35 NA Earth
## 36 37166 Earth
## 37 2008 Earth
## 38 1965 Earth
## 39 NA Earth
## 40 1666 Earth
## 41 NA
## 42 2009 Earth
## 43 NA Indian Ocean, Planet Inter Minor
## 44 1966 Earth
## 45 5000000053 Earth
## 46 NA Earth
## 47 NA Earth
## 48 3295 Earth
## 49 NA Earth
## 50 1983 Earth
## 51 2007 Earth
## 52 NA Earth
## 53 4687 Earth
## 54 NA Earth
## 55 1881 Earth
## 56 2070 Earth
## 57 NA Earth
## 58 1970 Earth
## 59 NA Earth
## 60 NA Earth
## 61 NA Earth
## 62 1930 Earth
## 63 NA Earth
## 64 NA Earth
## 65 2472 Earth
## 66 NA Earth/ Atlantis
## 67 NA Earth
## 68 NA Earth
## 69 5000 Earth
## 70 NA Earth
## 71 2116 Earth
## 72 1911 Planet: Oseidon; also village of Devesham
## 73 1492 Earth
## 74 NA ????
## 75 NA Earth
## 76 NA earth
## 77 NA Gallifrey, Earth
## 78 NA earth
## 79 NA earth
## 80 NA Earth
## 81 10000000 earth
## 82 1671 Earth
## 83 1943 Earth
## 84 NA Earth
## 85 NA Earth
## 86 NA Earth
## 87 NA Earth
## 88 NA Earth
## 89 NA Earth
## 90 NA Earth
## 91 1987 Earth
## 92 NA Earth
## 93 1869 Earth
## 94 NA Earth
## 95 1879 Earth
## 96 1764 Earth
## 97 1930 Earth
## 99 NA Earth
## 100 NA Earth
## 101 2700 Earth
## 102 NA Earth
## 103 4126 Earth
## 104 1851 Earth
## 105 NA Earth
## 106 NA Earth
## 107 NA Dundra System to Earth
## 108 NA Earth
## 109 NA Earth
## 110 NA Earth
## 111 NA Earth
## 112 NA Earth
## 113 NA Earth
## 114 2006 Earth
## 115 NA Earth
## 116 2010 Earth
## 117 1982 earth
## 118 NA Earth
## 119 NA Earth
## 120 NA Earth
## 121 1987 Earth
## 122 NA Earth
## 123 NA Earth
## 124 NA Earth
## 125 NA earth
## 126 NA earth
## 127 1066 Earth
## 128 NA Earth
## 129 NA
## 130 NA Earth
## 131 NA Earth and other planets
## 132 NA Earth
## 133 NA space
## 134 NA Earth
## 135 NA
## sub.location
## 1 England
## 2 n/a
## 3
## 4
## 5
## 6 Italy
## 7 Roman Empire
## 8 England
## 9 UK
## 10
## 11 UK
## 12 China
## 13 Mexico
## 14 France
## 15
## 16 England
## 17 England
## 18 UK
## 19 Earth and a parallel Earth
## 20 France
## 21 UK
## 22 Scotland
## 23 France
## 24 France
## 25 France
## 26 France
## 27 England
## 28
## 29 England
## 30
## 31 Scotland
## 32 USA
## 33 England
## 34 England
## 35
## 36 England
## 37 England
## 38 USA
## 39 England
## 40 England
## 41
## 42 Yorkshire
## 43 Ocean, alien planet
## 44
## 45 USA
## 46 Berlin
## 47 England
## 48 England
## 49
## 50 England
## 51 England
## 52
## 53 England
## 54 UK
## 55 UK
## 56 UK\n
## 57 UK
## 58 UK
## 59 England
## 60 England and USA
## 61 Utah
## 62 UK
## 63 UK
## 64 USA
## 65 England
## 66
## 67 UK
## 68 UK
## 69 England
## 70 France; Italy
## 71 England
## 72 England
## 73 England
## 74
## 75 England
## 76
## 77
## 78 England
## 79 England
## 80 England
## 81 England
## 82
## 83 England
## 84 England
## 85 England
## 86 England
## 87 England
## 88 Africa
## 89 England
## 90 England
## 91 USA
## 92 England
## 93 England
## 94 England
## 95 England
## 96 England
## 97 England
## 99 England
## 100 England
## 101
## 102 England
## 103 England
## 104
## 105
## 106 England
## 107
## 108
## 109 France
## 110 England and Planet One
## 111 England
## 112 England
## 113 USA
## 114 USA
## 115 England
## 116 UK
## 117
## 118 England
## 119 n/a
## 120 n/a
## 121
## 122 UK
## 123 UK
## 124
## 125 England
## 126
## 127
## 128 England
## 129
## 130
## 131
## 132 England
## 133
## 134 England
## 135
## location
## 1 London
## 2 n/a
## 3 Egypt
## 4
## 5 Asia Minor/Troy
## 6 Rome
## 7 Pompeii
## 8 to Stonehenge
## 9 Northumbria
## 10 Palestine
## 11 Wessex Castle
## 12 multiple
## 13
## 14 Paris
## 15 Leadworth to Venice
## 16 London
## 17 London
## 18 Cornwall
## 19 The Fancy (Ship)
## 20 Paris
## 21 Culloden
## 22 battle of Culloden
## 23 Versailles
## 24 Versailles
## 25 Versailles
## 26 Paris
## 27 Killingworth
## 28 London
## 29 Cardiff
## 30 Atlantic Ocean
## 31 Torchwood house, Near Balmoral
## 32 tombstone, arizona
## 33 Scotland
## 34 London
## 35
## 36 The site of UNIT HQ, years before it was built. Currently, a priory.
## 37 Farringham
## 38 Hollywood
## 39 Hull
## 40 Cranleigh Halt
## 41 "the land of fiction"
## 42 Harrogate
## 43
## 44 Tibet
## 45 Manhattan, New York
## 46 Germany
## 47 London
## 48 London
## 49 France to London
## 50 Maiden's Point, Northumberland
## 51 London
## 52
## 53 London
## 54 Liverpool
## 55 London
## 56 Gatwick Airport\nEarth orbit
## 57 London\nSkaro
## 58 North Sea
## 59 London
## 60 London to Utah
## 61 Amercia
## 62 London
## 63 Just outside London
## 64 Utah to Cape Kennedy
## 65 Devil's End, Wiltshire
## 66
## 67 Llanfairfach, Wales
## 68 London
## 69 Fetch Priory
## 70 Paris; Italy
## 71 Cambridge
## 72
## 73 Planet: Kastria;
## 74 City of Castrovalva
## 75 Heathrow
## 76 England
## 77
## 78 Brendon, London
## 79 Little Hodcombe
## 80 Gabriel's Chase, Perivale
## 81 London
## 82 South Pole
## 83 Perivale
## 84 London
## 85
## 86 London and other
## 87 Lake Vortigern
## 88 Ghana
## 89 London
## 90 National Museum, London
## 91 San Francisco
## 92 London
## 93 London
## 94 Cardiff
## 95 Deffry Vale
## 96 London (Parallel)
## 97 London
## 99 Malcassairo and London
## 100 Alternative England and London
## 101 London
## 102 Leadworth
## 103 London
## 104 San Helios, London
## 105 London
## 106 Leadworth
## 107 Alfava Metraxis to Leadworth
## 108 Leadworth
## 109 Auvers-sur-Oise to Paris
## 110 Stonehenge to Leadworth and Planet One
## 111 Stonehenge to Leadworth
## 112 Aickman Road, Colchester
## 113
## 114 Utah
## 115 London
## 116 Cwmtaff, Wales
## 117
## 118 Auderly House and environs
## 119 n/a
## 120 n/a
## 121
## 122 London
## 123 space museum, London; the moon
## 124
## 125 London
## 126 Terminus Station
## 127 Kembel
## 128 South Wales
## 129 The Byzantium
## 130
## 131 London to Stormcage Containment Facility, The Royal Collection and The Maldovarium
## 132
## 133 Earth orbit
## 134 Cardiff and Malcassairo
## 135
Tospread the data Iit is in the long format, need to be transformed into wide format), and eleimnate the col nont needed
Data51 <-
Data31 %>%
spread(planet,sub.location ) %>%
group_by(from) %>%
arrange(from)
## Warning: package 'bindrcpp' was built under R version 3.3.3
# this (from) variable is the year variable
summary (Data51)
## Doctor.Who.season doctor.actor ep..no from
## 11 :27 Smith :27 12 : 6 2007 : 6
## 10 :25 Tennant :26 1 : 5 2008 : 5
## 1 :21 Hartnell :21 13 : 5 2009 : 5
## 5 :12 Davison :12 204 : 4 2005 : 4
## 2 :11 Troughton:11 Special: 4 1963 : 3
## 3 : 9 Pertwee : 9 21 : 3 1966 : 3
## (Other):29 (Other) :28 (Other):107 (Other):108
## estimated.from location V1
## Min. :1.066e+03 London :23 : 3
## 1st Qu.:1.936e+03 :16 n/a : 1
## Median :1.987e+03 Leadworth : 3 UK : 1
## Mean :1.965e+08 n/a : 3 Africa : 0
## 3rd Qu.:2.800e+03 Paris : 3 Berlin : 0
## Max. :5.000e+09 Versailles: 3 (Other): 0
## NA's :83 (Other) :83 NA's :129
## ???? Dundra System to Earth
## : 1 : 1
## Africa : 0 Africa : 0
## Berlin : 0 Berlin : 0
## China : 0 China : 0
## Earth and a parallel Earth: 0 Earth and a parallel Earth: 0
## (Other) : 0 (Other) : 0
## NA's :133 NA's :133
## earth Earth Earth and other planets
## England: 6 England:47 : 1
## : 3 :19 Africa : 0
## Africa : 0 UK :14 Berlin : 0
## Berlin : 0 France : 7 China : 0
## China : 0 USA : 7 Earth and a parallel Earth: 0
## (Other): 0 (Other):17 (Other) : 0
## NA's :125 NA's :23 NA's :133
## Earth/ Atlantis Gallifrey, Earth
## : 2 : 1
## Africa : 0 Africa : 0
## Berlin : 0 Berlin : 0
## China : 0 China : 0
## Earth and a parallel Earth: 0 Earth and a parallel Earth: 0
## (Other) : 0 (Other) : 0
## NA's :132 NA's :133
## Indian Ocean, Planet Inter Minor
## Ocean, alien planet: 1
## : 0
## Africa : 0
## Berlin : 0
## China : 0
## (Other) : 0
## NA's :133
## Planet: Oseidon; also village of Devesham
## England: 1
## : 0
## Africa : 0
## Berlin : 0
## China : 0
## (Other): 0
## NA's :133
## space
## : 1
## Africa : 0
## Berlin : 0
## China : 0
## Earth and a parallel Earth: 0
## (Other) : 0
## NA's :133
head(Data51)
## # A tibble: 6 x 17
## # Groups: from [5]
## Doctor.Who.seas~ doctor.actor ep..no from estimated.from location V1
## <fct> <fct> <fct> <fct> <dbl> <fct> <fct>
## 1 SEASON 1 "" "" "" NA "" ""
## 2 5 Davison 125 -1017 NA Brendon~ <NA>
## 3 1 Hartnell 20 -1200 3999 Asia Mi~ <NA>
## 4 1 Hartnell 4 -13,~ NA multiple <NA>
## 5 5 Davison 116 -137~ NA City of~ <NA>
## 6 5 Davison 126 -137~ NA Terminu~ <NA>
## # ... with 10 more variables: `????` <fct>, `Dundra System to
## # Earth` <fct>, earth <fct>, Earth <fct>, `Earth and other
## # planets` <fct>, `Earth/ Atlantis` <fct>, `Gallifrey, Earth` <fct>,
## # `Indian Ocean, Planet Inter Minor` <fct>, `Planet: Oseidon; also
## # village of Devesham` <fct>, space <fct>
tail(Data51)
## # A tibble: 6 x 17
## # Groups: from [5]
## Doctor.Who.seas~ doctor.actor ep..no from estimated.from location V1
## <fct> <fct> <fct> <fct> <dbl> <fct> <fct>
## 1 11 Smith 5 5000 NA Alfava ~ <NA>
## 2 11 Smith 8 5100 NA Germany <NA>
## 3 11 Smith 13 5100 NA Amercia <NA>
## 4 11 Smith 12 5145 NA to Ston~ <NA>
## 5 1 Hartnell 12 64 2493 Rome <NA>
## 6 7 McCoy 152 793 NA Lake Vo~ <NA>
## # ... with 10 more variables: `????` <fct>, `Dundra System to
## # Earth` <fct>, earth <fct>, Earth <fct>, `Earth and other
## # planets` <fct>, `Earth/ Atlantis` <fct>, `Gallifrey, Earth` <fct>,
## # `Indian Ocean, Planet Inter Minor` <fct>, `Planet: Oseidon; also
## # village of Devesham` <fct>, space <fct>
#print(Data51)
#write.csv (Data11,'Data51DoctorsWhoTravel.csv')
# this is 135*6 dimension table,
# Analyse the data by season of the show
Data71 <- Data51 %>%
group_by (Doctor.Who.season)
head(Data71)
## # A tibble: 6 x 17
## # Groups: Doctor.Who.season [3]
## Doctor.Who.seas~ doctor.actor ep..no from estimated.from location V1
## <fct> <fct> <fct> <fct> <dbl> <fct> <fct>
## 1 SEASON 1 "" "" "" NA "" ""
## 2 5 Davison 125 -1017 NA Brendon~ <NA>
## 3 1 Hartnell 20 -1200 3999 Asia Mi~ <NA>
## 4 1 Hartnell 4 -13,~ NA multiple <NA>
## 5 5 Davison 116 -137~ NA City of~ <NA>
## 6 5 Davison 126 -137~ NA Terminu~ <NA>
## # ... with 10 more variables: `????` <fct>, `Dundra System to
## # Earth` <fct>, earth <fct>, Earth <fct>, `Earth and other
## # planets` <fct>, `Earth/ Atlantis` <fct>, `Gallifrey, Earth` <fct>,
## # `Indian Ocean, Planet Inter Minor` <fct>, `Planet: Oseidon; also
## # village of Devesham` <fct>, space <fct>
tail (Data71)
## # A tibble: 6 x 17
## # Groups: Doctor.Who.season [3]
## Doctor.Who.seas~ doctor.actor ep..no from estimated.from location V1
## <fct> <fct> <fct> <fct> <dbl> <fct> <fct>
## 1 11 Smith 5 5000 NA Alfava ~ <NA>
## 2 11 Smith 8 5100 NA Germany <NA>
## 3 11 Smith 13 5100 NA Amercia <NA>
## 4 11 Smith 12 5145 NA to Ston~ <NA>
## 5 1 Hartnell 12 64 2493 Rome <NA>
## 6 7 McCoy 152 793 NA Lake Vo~ <NA>
## # ... with 10 more variables: `????` <fct>, `Dundra System to
## # Earth` <fct>, earth <fct>, Earth <fct>, `Earth and other
## # planets` <fct>, `Earth/ Atlantis` <fct>, `Gallifrey, Earth` <fct>,
## # `Indian Ocean, Planet Inter Minor` <fct>, `Planet: Oseidon; also
## # village of Devesham` <fct>, space <fct>
print(Data71)
## # A tibble: 134 x 17
## # Groups: Doctor.Who.season [13]
## Doctor.Who.seas~ doctor.actor ep..no from estimated.from location V1
## <fct> <fct> <fct> <fct> <dbl> <fct> <fct>
## 1 SEASON 1 "" "" "" NA "" ""
## 2 5 Davison 125 -1017 NA Brendon~ <NA>
## 3 1 Hartnell 20 -1200 3999 Asia Mi~ <NA>
## 4 1 Hartnell 4 -13,~ NA multiple <NA>
## 5 5 Davison 116 -137~ NA City of~ <NA>
## 6 5 Davison 126 -137~ NA Terminu~ <NA>
## 7 5 Davison 122 -140~ NA Heathrow <NA>
## 8 3 Pertwee 64 -2000 NA "" <NA>
## 9 1 Hartnell 21 -2500 4000 Egypt <NA>
## 10 4 Baker 105 -4.0~ NA Paris; ~ <NA>
## # ... with 124 more rows, and 10 more variables: `????` <fct>, `Dundra
## # System to Earth` <fct>, earth <fct>, Earth <fct>, `Earth and other
## # planets` <fct>, `Earth/ Atlantis` <fct>, `Gallifrey, Earth` <fct>,
## # `Indian Ocean, Planet Inter Minor` <fct>, `Planet: Oseidon; also
## # village of Devesham` <fct>, space <fct>
```
#write.csv (Data71,'Data71DoctorsWhoTravel.csv')
# this is 135 * 17 dimention