***Importing Dataset from Excel*** cd "\\Files\qalbaugh\ClusterDownloads\phds\Analysis\" * cd "C:\Users\quinn\Dropbox\phds\Analysis\" import excel "phdsdata.xls", sheet("Political Science Professors") firstrow clear *** Make the replication code run more smoothly set more off ***Clear out other data from 2013 that is no longer applicable rename VerificationNotes exclusion keep if exclusion=="" drop if Rank=="Senior Lecturer" drop DateCollected DateVerified exclusion Exclude ReasontoExclude tab PhDInstitution ***PhDs from other Fields" rename OtherPhDFieldifany phdfield label variable phdfield "PhD Field, if not political science" replace phdfield="Sociology" if PhDInstitution=="Paris, Sociology" replace phdfield="Indigenous Studies" if PhDInstitution=="Trent (Indigenous Studies)" replace phdfield="Economics" if PhDInstitution=="Manitoba (Economics)" tab phdfield keep if phdfield=="" ***Professors without PhDs drop if PhDInstitution=="None" drop if PhDInstitution=="LL.M. Cambridge" *** RECODING RANK tab Rank gen rank3 = . replace rank3 = 1 if Rank == "Assistant" replace rank3 = 2 if regexm(Rank,"Associate") replace rank3 = 3 if regexm(Rank,"Full") | Rank == "Professor" tab rank3 drop Rank rename rank3 rank ***GENERATING IDs*** by University, sort: gen id=_n ***FIXING PROVINCE VARIABLE*** tab Province gen province=1 if Province=="NL" replace province=2 if Province=="NS" replace province=3 if Province=="NB" replace province=4 if Province=="PE" replace province=5 if Province=="QC" replace province=6 if Province=="ON" replace province=7 if Province=="MB" replace province=8 if Province=="SK" replace province=9 if Province=="AB" replace province=10 if Province=="BC" label define prov 1 "Newfoundland and Labrador" 2 "Nova Scotia" 3 "New Brunswick" 4 "Prince Edward Island" 5 "Quebec" 6 "Ontario" 7 "Manitoba" 8 "Saskatchewan" 9 "Alberta" 10 "British Columbia" label values province prov tab province drop Province ***FIXING UNIVERSITY VARIABLE*** set more off tab University gen university=1 if University=="Acadia University " replace university=2 if University=="Algoma University" replace university=3 if University=="Athabasca University" replace university=4 if University=="Bishop's University" replace university=5 if University=="Brandon University" replace university=6 if University=="Brescia University College" replace university=7 if University=="Brock University" replace university=8 if University=="Cape Breton University" replace university=9 if University=="Capilano University" replace university=10 if University=="Carleton University" replace university=11 if University=="Concordia" *"Concordia University" replace university=12 if University=="Dalhousie" *"Dalhousie University" replace university=13 if University=="Dominican University College" replace university=14 if University=="Huron University College" replace university=15 if University=="King's University College" replace university=16 if University=="Kings University College" *"King's University College (Alberta)" replace university=17 if University=="Kwantlen Polytechnic" *"Kwantlen Polytechnic University" replace university=18 if University=="Lakehead University" replace university=19 if University=="Laurentian University" replace university=20 if University=="MacEwan" *"Grant MacEwan University" replace university=21 if University=="McGill" *"McGill University" replace university=22 if University=="McMaster" *"McMaster University" replace university=23 if University=="Memorial" *"Memorial University" replace university=24 if University=="Mount Allison" *"Mount Allison University" replace university=25 if University=="Mount Royal University" replace university=26 if University=="Mount Saint Vincent" *"Mount Saint Vincent University" replace university=27 if University=="Nipissing" *"Nipissing University" replace university=28 if University=="Queen's University" replace university=29 if University=="Redeemer University College" replace university=30 if University=="Royal Military College of Canada " replace university=31 if University=="Ryerson" *"Ryerson University" replace university=32 if University=="SFX" *"Saint Francis Xavier University" replace university=33 if University=="Saint Mary's University" replace university=34 if regexm(University,"Thomas More") *St. Thomas More College (University of Saskatchewan)" replace university=35 if University=="Simon Fraser" *"Simon Fraser University" replace university=36 if University=="St. Thomas University" replace university=37 if University=="Thomson Rivers" *"Thomson Rivers University" replace university=38 if University=="Trent" *"Trent University" replace university=39 if University=="Trinity Western University" replace university=40 if University=="University of Alberta" replace university=41 if University=="UBC" *"University of British Columbia" replace university=42 if University=="University of Calgary" replace university=43 if University=="Guelph" *"University of Guelph" replace university=44 if University=="Lethbridge" *"University of Lethbridge" replace university=45 if University=="University of Manitoba" replace university=46 if University=="UNB-Fredericton" *"University of New Brunswick - Fredericton" replace university=47 if University=="UNB-Saint John" *"University of New Brunswick - Saint John" replace university=48 if University=="UNBC" *"University of Northern British Columbia" replace university=49 if University=="University of Ottawa" replace university=50 if University=="University of Prince Edward Island" replace university=51 if University=="University of Regina" replace university=52 if University=="University of Saskatchewan" replace university=53 if University=="Toronto" *"University of Toronto" replace university=54 if University=="Uvic" *"University of Victoria" replace university=55 if University=="University of Waterloo" replace university=56 if University=="University of Windsor" replace university=57 if University=="University of Winnipeg" replace university=58 if University=="University of the Fraser Valley" replace university=59 if University=="Universite Laval" replace university=60 if University=="Moncton" *"Universite Moncton" replace university=61 if University=="Universite de Montreal" replace university=62 if University=="Universite de Sherbrooke" replace university=63 if University=="Universite du Quebec a Montreal " replace university=64 if University=="Vancouver Island University" replace university=65 if University=="Western" *"Western University" replace university=66 if University=="Wilfried Laurier University" *"Wilfrid Laurier University" replace university=67 if University=="York" *"York University" replace university=68 if University=="Glendon" *"York University" tab university label define univ 1 "Acadia University" 2 "Algoma University" 3 "Athabasca University" 4 "Bishop's University" 5 "Brandon University" 6 "Brescia University College (Western)" 7 "Brock University" 8 "Cape Breton University" 9 "Capilano University" 10 "Carleton University" 11 "Concordia University" 12 "Dalhousie University" 13 "Dominican University College" 14 "Huron University College (Western)" 15 "King's University College (Western)" 16 "King's University College (Alberta)" 17 "Kwantlen Polytechnic University" 18 "Lakehead University" 19 "Laurentian University" 20 "Grant MacEwan University" 21 "McGill University" 22 "McMaster University" 23 "Memorial University" 24 "Mount Allison University" 25 "Mount Royal University" 26 "Mount Saint Vincent University" 27 "Nipissing University" 28 "Queen's University" 29 "Redeemer University College" 30 "Royal Military College of Canada" 31 "Ryerson University" 32 "Saint Francis Xavier University" 33 "Saint Mary's University" 34 "St. Thomas More College (University of Saskatchewan)" 35 "Simon Fraser University" 36 "St. Thomas University" 37 "Thomson Rivers University" 38 "Trent University" 39 "Trinity Western University" 40 "University of Alberta" 41 "University of British Columbia" 42 "University of Calgary" 43 "University of Guelph" 44 "University of Lethbridge" 45 "University of Manitoba" 46 "University of New Brunswick - Fredericton" 47 "University of New Brunswick - Saint John" 48 "University of Northern British Columbia" 49 "University of Ottawa" 50 "University of Prince Edward Island" 51 "University of Regina" 52 "University of Saskatchewan" 53 "University of Toronto" 54 "University of Victoria" 55 "University of Waterloo" 56 "University of Windsor" 57 "University of Winnipeg" 58 "University of the Fraser Valley" 59 "Universite Laval" 60 "Universite Moncton" 61 "Universite de Montreal" 62 "Universite Sherbrooke" 63 "Universite du Québec à Montreal" 64 "Vancouver Island University" 65 "Western University" 66 "Wilfrid Laurier University" 67 "York University" 68 "Glendon College, York Univesrity" label values university univ tab University if university==. drop University Department tab university ***RENAMING VARIABLES*** rename Name name rename PhDYear Year rename Subfield1 subfield1 rename Subfield2 subfield2 rename Subfield3 subfield3 rename Year year rename PhDInstitution phdi ***SUBFIELDS*** generate subfield=1 if subfield1=="Canadian" replace subfield=1 if subfield1=="Canadian " replace subfield=1 if subfield1=="Canadian and Quebec Politics" replace subfield=2 if subfield1=="Comparative" replace subfield=2 if subfield1=="Comparative " replace subfield=2 if subfield1=="Comparative Politics" replace subfield=2 if subfield1=="Compartive" replace subfield=3 if subfield1=="IR" replace subfield=4 if subfield1=="Political Theory or Philosophy" replace subfield=5 if subfield1=="Public Administration" replace subfield=5 if subfield1=="Public Policy or Administration" replace subfield=5 if subfield1=="Public Policy or Administration and Public Administration" replace subfield=6 if subfield==. replace subfield=. if subfield1=="?" label define subf 1 "Canadian Politics" 2 "Comparative Politics" 3 "International Relations" 4 "Political Theory/Philosophy" 5 "Public Policy/Administration" 6 "Other" label values subfield subf tab subfield generate subfieldx=1 if subfield1=="Canadian" replace subfieldx=1 if subfield1=="Canadian " replace subfieldx=1 if subfield1=="Canadian and Quebec Politics" replace subfieldx=1 if subfield2=="Canadian" replace subfieldx=1 if subfield2=="Canadian " replace subfieldx=1 if subfield2=="Canadian and Quebec Politics" replace subfieldx=1 if subfield3=="Canadian" replace subfieldx=1 if subfield3=="Canadian " replace subfieldx=1 if subfield3=="Canadian and Quebec Politics" replace subfieldx=2 if subfield1=="Comparative" replace subfieldx=2 if subfield1=="Comparative " replace subfieldx=2 if subfield1=="Comparative Politics" replace subfieldx=2 if subfield1=="Compartive" replace subfieldx=2 if subfield2=="Comparative" replace subfieldx=2 if subfield2=="Comparative " replace subfieldx=2 if subfield2=="Comparative Politics" replace subfieldx=2 if subfield2=="Compartive" replace subfieldx=2 if subfield3=="Comparative" replace subfieldx=2 if subfield3=="Comparative " replace subfieldx=2 if subfield3=="Comparative Politics" replace subfieldx=2 if subfield3=="Compartive" replace subfieldx=3 if subfield1=="IR" replace subfieldx=3 if subfield2=="IR" replace subfieldx=3 if subfield3=="IR" replace subfieldx=4 if subfield1=="Political Theory or Philosophy" replace subfieldx=4 if subfield2=="Political Theory or Philosophy" replace subfieldx=4 if subfield3=="Political Theory or Philosophy" replace subfieldx=5 if subfield1=="Public Administration" replace subfieldx=5 if subfield1=="Public Policy or Administration" replace subfieldx=5 if subfield1=="Public Policy or Administration and Public Administration" replace subfieldx=5 if subfield2=="Public Administration" replace subfieldx=5 if subfield2=="Public Policy or Administration" replace subfieldx=5 if subfield2=="Public Policy or Administration and Public Administration" replace subfieldx=5 if subfield3=="Public Administration" replace subfieldx=5 if subfield3=="Public Policy or Administration" replace subfieldx=5 if subfield3=="Public Policy or Administration and Public Administration" replace subfield=6 if subfield==. replace subfield=. if subfield1=="?" label values subfieldx subf tab subfieldx ***Cleaning Up PhD Institution" tab phdi replace phdi="UQAM" if regexm(phdi, "UQAM") replace phdi="Geneva" if regexm(phdi, "University of Geneva") replace phdi="London" if phdi=="University of London" replace phdi="McGill" if phdi=="McGill " replace phdi="EHESS" if regexm(phdi, "EHESS") replace phdi="EHESS" if regexm(phdi, "Hautes") replace phdi="Wisconsin" if regexm(phdi, "Wisconsin") replace phdi="Paris 7" if regexm(phdi, "Paris 7") replace phdi="Paris 7" if regexm(phdi, "Paris VII") replace phdi="Montreal" if regexm(phdi, "Montreal") replace phdi="McMaster" if regexm(phdi, "McMaster") replace phdi="Texas" if regexm(phdi, "UT-Austin") replace phdi="Sciences Po-Aix" if regexm(phdi, "Sciences Po Aix") replace phdi="Rennes 1" if regexm(phdi, "Rennes I") replace phdi="Rennes 1" if regexm(phdi, "Rennes 1") replace phdi="Paris I - Sorbonne" if regexm(phdi, "Paris 1") replace phdi="Geneva" if regexm(phdi, "Graduate Ins") tab phdi ***GENERATING VARIABLE OF INTEREST: PHD GRANTING INSTITUTION*** gen phd=143 replace phd=1 if phdi=="Toronto" replace phd=2 if phdi=="York" replace phd=3 if phdi=="Carleton" replace phd=4 if phdi=="Queen's" replace phd=5 if phdi=="UBC" replace phd=6 if phdi=="McGill" replace phd=7 if phdi=="Alberta" replace phd=8 if phdi=="Oxford" replace phd=9 if phdi=="Princeton" replace phd=10 if phdi=="Harvard" replace phd=11 if phdi=="Montreal" replace phd=12 if phdi=="LSE " replace phd=13 if phdi=="McMaster" replace phd=14 if phdi=="Western" replace phd=15 if phdi=="Columbia" replace phd=16 if regexm(phdi,"Dalhousie") replace phd=17 if phdi=="Yale" replace phd=18 if phdi=="Laval" replace phd=19 if phdi=="Calgary" replace phd=20 if phdi=="UQAM" replace phd=21 if phdi=="Berkeley" replace phd=22 if phdi=="Minnesota" replace phd=23 if phdi=="Cambridge" replace phd=24 if phdi=="Cornell" replace phd=25 if phdi=="Duke" replace phd=26 if phdi=="Johns Hopkins" replace phd=27 if phdi=="London" replace phd=28 if phdi=="Stanford" replace phd=29 if phdi=="Chicago" replace phd=30 if phdi=="GWU" replace phd=31 if phdi=="Northwestern" replace phd=32 if phdi=="Sciences Po" replace phd=33 if phdi=="Wisconsin" replace phd=34 if phdi=="MIT" replace phd=35 if phdi=="Penn" replace phd=36 if phdi=="EHESS" replace phd=37 if phdi=="Georgetown" replace phd=38 if phdi=="Indiana University" replace phd=39 if phdi=="Michigan" replace phd=40 if phdi=="New School" replace phd=41 if phdi=="Paris I - Sorbonne" replace phd=42 if phdi=="Sussex" replace phd=43 if phdi=="Brandeis" replace phd=44 if phdi=="Geneva" replace phd=45 if phdi=="Notre Dame" replace phd=46 if phdi=="Paris 7" replace phd=47 if phdi=="Rochester" replace phd=48 if phdi=="Sciences Po-Aix" replace phd=49 if phdi=="Syracuse" replace phd=50 if phdi=="UCLA" replace phd=51 if phdi=="Birmingham" replace phd=52 if phdi=="Claremont University" replace phd=53 if phdi=="Concordia" replace phd=54 if phdi=="Denver" replace phd=55 if regexm(phdi,"European Univ. Inst") replace phd=56 if phdi=="Florida" replace phd=57 if phdi=="Fordham" replace phd=58 if phdi=="Illinois" replace phd=59 if phdi=="Melbourne" replace phd=60 if phdi=="NYU" replace phd=61 if phdi=="Northern Illinois University" replace phd=62 if phdi=="Ottawa" replace phd=63 if phdi=="Penn State" replace phd=64 if phdi=="Rennes 1" replace phd=65 if phdi=="Simon Fraser" replace phd=66 if phdi=="UCSD" replace phd=67 if phdi=="UNC-Chapel Hill" replace phd=68 if regexm(phdi,"St. Andrews") replace phd=69 if phdi=="Texas" replace phd=70 if phdi=="University of Washington" *** FIX THE UNIVERSITIES FROM HERE * new universities replace phd=71 if regexm(phdi,"Maryland") replace phd=72 if regexm(phdi,"Virginia") replace phd=73 if regexm(phdi,"U Mass - Amherst") replace phd=74 if regexm(phdi,"New Mexico") replace phd=75 if regexm(phdi,"Colorado") replace phd=76 if regexm(phdi,"Tufts") replace phd=77 if regexm(phdi,"Aix-Marseille") replace phd=78 if regexm(phdi,"Albany") replace phd=79 if regexm(phdi,"Arizona State") replace phd=80 if regexm(phdi,"Augsburg") replace phd=81 if regexm(phdi,"Australian National University") replace phd=82 if regexm(phdi,"Bath") replace phd=83 if regexm(phdi,"Baylor") replace phd=84 if regexm(phdi,"Binghamton") replace phd=85 if regexm(phdi,"Bremen") replace phd=86 if regexm(phdi,"Bristol") replace phd=87 if regexm(phdi,"Brown") replace phd=88 if regexm(phdi,"Central European University") replace phd=89 if regexm(phdi,"Connecticut") replace phd=90 if regexm(phdi,"Durham") replace phd=91 if regexm(phdi,"ENAP") replace phd=92 if regexm(phdi,"Essex") replace phd=93 if regexm(phdi,"Frankfurt") replace phd=94 if regexm(phdi,"Free University Berlin") replace phd=95 if regexm(phdi,"Hawaii") replace phd=96 if regexm(phdi,"Heidelberg") replace phd=97 if regexm(phdi,"Institute of Development Studies") replace phd=98 if regexm(phdi,"Johann Wolfgang Goethe University Fra..") replace phd=99 if regexm(phdi,"Justus-Liebig-University of Giessen") replace phd=100 if regexm(phdi,"Lancaster") replace phd=101 if regexm(phdi,"Leicester") replace phd=102 if regexm(phdi,"Leuven") replace phd=103 if regexm(phdi,"Lille") replace phd=104 if regexm(phdi,"London (Queen Mary)") replace phd=105 if regexm(phdi,"Louvain") replace phd=106 if regexm(phdi,"Manitoba") replace phd=107 if regexm(phdi,"Michigan State") replace phd=108 if regexm(phdi,"Monash") replace phd=109 if regexm(phdi,"North Texas") replace phd=110 if regexm(phdi,"Ohio State") replace phd=111 if regexm(phdi,"Oslo") replace phd=112 if regexm(phdi,"Ottawa or New School") replace phd=113 if regexm(phdi,"Paris") replace phd=114 if regexm(phdi,"Pittsburgh") replace phd=115 if regexm(phdi,"Purdue") replace phd=116 if regexm(phdi,"Queen's University Belfast") replace phd=116 if regexm(phdi,"Queens University - Belfast") replace phd=118 if regexm(phdi,"Reading") replace phd=119 if regexm(phdi,"Royal Military College of Canada") replace phd=120 if regexm(phdi,"Russian Academy of Science") replace phd=121 if regexm(phdi,"Rutgers") replace phd=122 if regexm(phdi,"Ryerson") replace phd=123 if regexm(phdi,"Sao Paulo") replace phd=124 if regexm(phdi,"Sciences Po - Bordeaux") replace phd=125 if regexm(phdi,"Sciences Po - Strasbourg") replace phd=126 if regexm(phdi,"Sciences Po Grenoble") replace phd=124 if regexm(phdi,"Sciences Po – Bordeaux") replace phd=128 if regexm(phdi,"Soviet Academy of Sciences") replace phd=129 if regexm(phdi,"St. Gall University") replace phd=130 if regexm(phdi,"Trinity College Dublin") replace phd=131 if regexm(phdi,"UC Santa Barbara") replace phd=132 if regexm(phdi,"UC Santa Cruz") replace phd=133 if regexm(phdi,"USC") replace phd=134 if regexm(phdi,"Ukrainian Free University in Munich") replace phd=135 if regexm(phdi,"Universite Montesquieu-Bordeaux IV") replace phd=136 if regexm(phdi,"Universite libre de Bruxelles") replace phd=137 if regexm(phdi,"University of California, Irvine") replace phd=138 if regexm(phdi,"Victoria") replace phd=139 if regexm(phdi,"Waikato") replace phd=140 if regexm(phdi,"Washington University in St. Louis") replace phd=141 if regexm(phdi,"Waterloo") replace phd=142 if regexm(phdi,"Zurich") *** replace phd=143 if phdi=="?" rename phdi phdi label variable phdi "PhD Granting Institution, original text" label variable phd "PhD Granting Institution, Cleaned Up" set more off tab phd label define phd4 1 "University of Toronto" 2 "York University" 3 "Carleton University" 4 "Queen's University" 5 "University of British Columbia" 6 "McGill University" 7 "University of Alberta" 8 "Oxford University" 9 "Princeton University" 10 "Harvard University" 11 "Universite de Montréal" 12 "London School of Economics and Political Science" 13 "McMaster University" 14 "Western University" 15 "Columbia University" 16 "Dalhousie University" 17 "Yale University" 18 "Universite Laval" 19 "University of Calgary" 20 "Universite du Quebec a Montreal" 21 "University of California - Berkeley" 22 "University of Minnesota" 23 "Cambridge University" 24 "Cornell University" 25 "Duke University" 26 "Johns Hopkins University" 27 "University of London" 28 "Stanford University" 29 "University of Chicago" 30 "George Washington University" 31 "Northwestern University" 32 "Institut d'etudes politiques de Paris" 33 "University of Wisconsin" 34 "Massachusetts Institute of Technology" 35 "University of Pennsylvania" 36 "Ecole des Hautes Etudes en Sciences Sociales" 37 "Georgetown University" 38 "Indiana University" 39 "University of Michigan" 40 "New School for Social Research" 41 "Universite Paris 1 Pantheon-Sorbonne" 42 "University of Sussex" 43 "Brandeis University" 44 "Universite de Geneve" 45 "University of Notre Dame" 46 "Universite Paris VII - Diderot" 47 "University of Rochester" 48 "Institut d'Etudes Politiques d'Aix-en-Provence" 49 "Syracuse University" 50 "University of California - Lose Angeles" 51 "Birmingham University" 52 "Claremont Graduate University" 53 "Concordia University" 54 "University of Denver" 55 "European University Institute" 56 "University of Florida" 57 "Fordham University" 58 "University of Illinois" 59 "University of Melbourne" 60 "New York University" 61 "Northern Illinois University" 62 "University of Ottawa" 63 "Pennsylvania State University" 64 "Universite Rennes I" 65 "Simon Fraser University" 66 "University of California - San Diego" 67 "University of North Carolina - Chapel Hill" 68 "University of St Andrews" 69 "University of Texas" 70 "University of Washington" 71 "University of North Texas" 91 "École nationale d'administration publique" 106 "University of Manitoba" 119 "Ryerson University" 122 "Royal Military College of Canada" 138 "University of Victoria" 141 "University of Waterloo" 143 "Missing" tab phdi if phd==143 label values phd phd4 set more off tab phdi if phd==73 ***Save to Table 1*** ***PhD Country gen country=. replace country=1 if phdi=="Toronto" replace country=1 if phdi=="York" replace country=1 if phdi=="Carleton" replace country=1 if phdi=="Queen's" replace country=1 if phdi=="UBC" replace country=1 if phdi=="McGill" replace country=1 if phdi=="Alberta" replace country=3 if phdi=="Oxford" replace country=2 if phdi=="Princeton" replace country=2 if phdi=="Harvard" replace country=1 if phdi=="Montreal" replace country=3 if phdi=="LSE " replace country=1 if phdi=="McMaster" replace country=1 if phdi=="Western" replace country=2 if phdi=="Columbia" replace country=1 if phdi=="Dalhousie" replace country=2 if phdi=="Yale" replace country=1 if phdi=="Laval" replace country=1 if phdi=="Calgary" replace country=1 if phdi=="UQAM" replace country=2 if phdi=="Berkeley" replace country=2 if phdi=="Minnesota" replace country=3 if phdi=="Cambridge" replace country=2 if phdi=="Cornell" replace country=2 if phdi=="Duke" replace country=2 if phdi=="Johns Hopkins" replace country=3 if phdi=="London" replace country=2 if phdi=="Stanford" replace country=2 if phdi=="Chicago" replace country=2 if phdi=="GWU" replace country=2 if phdi=="Northwestern" replace country=4 if phdi=="Sciences Po" replace country=2 if phdi=="Wisconsin" replace country=2 if phdi=="MIT" replace country=2 if phdi=="Penn" replace country=3 if phdi=="EHESS" replace country=2 if phdi=="Georgetown" replace country=2 if phdi=="Indiana University" replace country=2 if phdi=="Michigan" replace country=2 if regexm(phdi,"New School") replace country=4 if phdi=="Paris I - Sorbonne" replace country=3 if phdi=="Sussex" replace country=2 if phdi=="Brandeis" replace country=6 if phdi=="Geneva" replace country=2 if phdi=="Notre Dame" replace country=4 if phdi=="Paris 7" replace country=2 if phdi=="Rochester" replace country=4 if phdi=="Sciences Po-Aix" replace country=2 if phdi=="Syracuse" replace country=2 if phdi=="UCLA" replace country=3 if phdi=="Birmingham" replace country=2 if phdi=="Claremont University" replace country=1 if phdi=="Concordia" replace country=2 if phdi=="Denver" replace country=9 if regexm(phdi,"European Univ. Inst") replace country=2 if phdi=="Florida" replace country=2 if phdi=="Fordham" replace country=2 if phdi=="Illinois" replace country=7 if phdi=="Melbourne" replace country=2 if phdi=="NYU" replace country=2 if phdi=="Northern Illinois University" replace country=1 if phdi=="Ottawa" replace country=2 if phdi=="Penn State" replace country=4 if phdi=="Rennes 1" replace country=1 if phdi=="Simon Fraser" replace country=2 if phdi=="UCSD" replace country=2 if phdi=="UNC-Chapel Hill" replace country=2 if regexm(phdi,"Texas") replace country=2 if regexm(phdi,"Washington") replace country=4 if regexm(phdi,"Aix-Marseille") replace country=2 if regexm(phdi,"Albany") replace country=2 if regexm(phdi,"Arizona State") replace country=7 if regexm(phdi,"Australian National University") replace country=2 if regexm(phdi,"Baylor") replace country=2 if regexm(phdi,"Binghamton") replace country=5 if regexm(phdi,"Bremen") replace country=3 if regexm(phdi,"Bristol") replace country=2 if regexm(phdi,"Brown") replace country=12 if regexm(phdi,"Charles University") replace country=2 if regexm(phdi,"Connecticut") replace country=17 if regexm(phdi,"Cordoba") replace country=3 if regexm(phdi,"Durham") replace country=3 if regexm(phdi,"Edinburgh") replace country=3 if regexm(phdi,"Essex") replace country=5 if regexm(phdi,"Frankfurt") replace country=5 if regexm(phdi,"Free University") replace country=2 if regexm(phdi,"Hawaii") replace country=5 if regexm(phdi,"Heidelburg") replace country=3 if regexm(phdi,"Development Studies") replace country=13 if regexm(phdi,"Jawaharlal Nehru University") replace country=5 if regexm(phdi,"Goethe") replace country=5 if regexm(phdi,"Giessen") replace country=3 if regexm(phdi,"Kent") replace country=3 if regexm(phdi,"Lancaster") replace country=4 if regexm(phdi,"Lille") replace country=8 if regexm(phdi,"Louvain") replace country=1 if regexm(phdi,"Manitoba") replace country=2 if regexm(phdi,"Michigan State") replace country=2 if regexm(phdi,"Ohio State") replace country=15 if regexm(phdi,"Oslo") replace country=4 if regexm(phdi,"Pierre-") replace country=2 if regexm(phdi,"Pittsburgh") replace country=2 if regexm(phdi,"Purdue") replace country=3 if regexm(phdi,"Reading") replace country=1 if regexm(phdi,"Royal Military") replace country=10 if regexm(phdi,"Russian Academy") replace country=11 if regexm(phdi,"Sao Paulo") replace country=10 if regexm(phdi,"Soviet Academy of Sciences") replace country=3 if regexm(phdi,"St. Andrews") replace country=4 if regexm(phdi,"Bordeaux") replace country=4 if regexm(phdi,"Strasbourg") replace country=4 if regexm(phdi,"Grenoble") replace country=6 if regexm(phdi,"St. Gall University") replace country=8 if regexm(phdi,"Darmstadt") replace country=14 if regexm(phdi,"Dublin") replace country=2 if regexm(phdi,"Tufts") replace country=2 if regexm(phdi,"Amherst") replace country=2 if regexm(phdi,"USC") replace country=5 if regexm(phdi,"Munich") replace country=2 if regexm(phdi,"Irvine") replace country=2 if regexm(phdi,"Maryland") replace country=2 if regexm(phdi,"New Mexico") replace country=16 if regexm(phdi,"Stellenbosch") replace country=4 if regexm(phdi,"Montesquieu") replace country=8 if regexm(phdi,"Bruxelles") replace country=1 if regexm(phdi,"Victoria") replace country=2 if regexm(phdi,"Virginia") replace country=6 if regexm(phdi,"Zurich") replace country=5 if regexm(phdi,"Augsburg") replace country=3 if regexm(phdi,"Bath") replace country=18 if regexm(phdi,"Central European University") replace country=1 if regexm(phdi,"ENAP") replace country=1 if regexm(phdi,"Ryerson") replace country=1 if regexm(phdi,"Waterloo") replace country=5 if regexm(phdi,"Heidelberg") replace country=3 if regexm(phdi,"Leicester") replace country=3 if regexm(phdi,"London") replace country=2 if regexm(phdi,"Virginia") replace country=2 if regexm(phdi,"Colorado") replace country=2 if regexm(phdi,"Rutgers") replace country=2 if regexm(phdi,"Santa Cruz") replace country=2 if regexm(phdi,"Santa Barbara") replace country=3 if regexm(phdi,"Belfast") replace country=4 if regexm(phdi,"Paris") replace country=8 if regexm(phdi,"Leuven") replace country=7 if regexm(phdi,"Monash") replace country=19 if regexm(phdi,"Waikato") label define country2 1 "Canada" 2 "United States of America" 3 "United Kingdom" 4 "France" 5 "Germany" 6 "Switzerland" 7 "Australia" 8 "Belgium" 9 "Italy" 10 "Russia" 11 "Brazil" 12 "Czech Republic" 13 "India" 14 "Ireland" 15 "Norway" 16 "South Africa" 17 "Spain" 18 "Hungary" 19 "New Zealand" label values country country2 tab country * key question: tables or figures for raw numbers of professors? *** TOP DEPARTMENTS tab phdi * Copy over to Excel, sort for top 25 *** COUNTRY OF PHD INSTITUTION * create a variable that just contains a 1 gen count = 1 gen assistant = 1 if rank == 1 * Figure 1: dotplot by countries overall graph dot (sum) count, over(country, sort((sum) count) descending) linetype(line) lines(lwidth(vthin)) m(1, msymbol(0) mcolor("black")) title("PhD-Granting Institutions, by Country", color("black")) ytitle("Number of Professors") ylab(0(100)500, nogrid) graphregion(color(white)) graph export "country.esp", as(eps) replace graph export "country.png", as(png) replace * Figure 2: dotplot by countries, assistant professors only graph dot (sum) assistant, over(country, sort((sum) count) descending) linetype(line) lines(lwidth(vthin)) m(1, msymbol(0) mcolor("black")) title("PhD-Granting Institutions, by Country", color("black")) ytitle("Number of Assistant Professors") ylab(0(25)150, nogrid) graphregion(color(white)) graph export "country-assistant.esp", as(eps) replace graph export "country-assistant.png", as(png) replace * Figure 3: dotplot of proportions of professors within each department who are American and Canadian gen canada = 0 replace canada = 100 if country==1 gen usa = 0 replace usa = 100 if country==2 graph dot (mean) canada (mean) usa, over(university, sort((mean) usa) descending label(labsize(tiny))) linetype(line) lines(lwidth(vthin)) m(1, mcolor("black")) m(2, mlcolor("black") mfcolor("white")) title("Country of PhD, by Department", color("black")) ytitle("Percentage of Department") ylab(0(25)100, nogrid) graphregion(color(white)) legend(label(1 "Canadian") label(2 "American")) graph export "country-department.esp", as(eps) replace graph export "country-department.png", as(png) replace *** TOP CANADIAN DEPARTMENTS tab phd if country==1 * copy to Excel sheet and reorder graph dot (sum) count if country==1, over(phd, sort((sum) count) descending) linetype(line) lines(lwidth(vthin)) m(1, msymbol(o) mfcolor("black")) title("PhD-Granting Institutions, Canadian Departments Only", color("black")) ytitle("Number of Professors") ylab(0(25)150, nogrid) graphregion(color(white)) *** MODAL PHD INSTITUTION BY DEPARTMENT by university, sort: tab phdi