Important to know

Question 1 (10 points)

For this assignment, you will be working with 2015 November Election Results from TUIK. Click here to download the data as an Excel document. Also, click here to download the assignment as an R Markdown document. You have to complete that document and return it to your instructor.

Your first task is to load the data into R. You are NOT allowed to change the XLS file in any way. All grading tests will be run on the original XLS file. If you assume a changed XLS file, than you risk losing full grades for the whole assignment.

Your Answer

## 'data.frame':    258 obs. of  23 variables:
##  $ Cevre                    : Factor w/ 86 levels "Adana","Adıyaman",..: 81 81 81 1 1 1 2 2 2 3 ...
##  $ Tip                      : Factor w/ 3 levels "Toplam","Yurt Dışı",..: 1 3 2 1 3 2 1 3 2 1 ...
##  $ Kayıtlı seçmen sayısı    : num  56949009 54049940 2899069 1483448 1483448 ...
##  $ Oy kullanan seçmen sayısı: num  48537695 47239370 1298325 1271890 1271890 ...
##  $ Katılım oranı (%)        : num  85.2 87.4 44.8 85.7 NA NA 85.2 NA NA 89 ...
##  $ Geçerli oy sayısı        : num  47840231 46555267 1284964 1290389 1255729 ...
##  $ MILLET PARTİSİ           : num  19714 19479 235 488 482 ...
##  $ VATAN PARTİSİ            : num  118803 114843 3960 2948 2841 ...
##  $ CHP                      : num  12111812 11900875 210937 379690 374000 ...
##  $ HAK-PAR                  : num  108583 106565 2018 2635 2581 ...
##  $ SAADET PARTİSİ           : num  325978 319543 6435 8175 8001 ...
##  $ DSP                      : num  31805 31523 282 782 774 ...
##  $ DP                       : num  69319 68862 457 1459 1447 ...
##  $ BTP                      : num  49297 48585 712 1107 1088 ...
##  $ MHP                      : num  5694136 5602469 91667 248655 246182 ...
##  $ HKP                      : num  83057 81207 1850 2106 2056 ...
##  $ LDP                      : num  26816 25163 1653 915 870 ...
##  $ HDP                      : num  5148085 4914203 233882 153880 147572 ...
##  $ BBP                      : num  253204 247354 5850 5028 4870 ...
##  $ AK PARTİ                 : num  23681926 22959394 722532 481851 462362 ...
##  $ KP                       : num  52527 50488 2039 658 603 ...
##  $ DYP                      : num  14131 13676 455 12 0 ...
##  $ BĞMZ                     : num  51038 51038 0 0 0 ...

Question 2 (20 points)

Plot the election results (vote distribution as percentages among parties) for all votes. Your plot must display the parties in descending sorted order.

Your Answer

Question 3 (20 points)

This time plot the percentages for “In country” and “Off Country” votes. Place them on the same plot, side by side to be able to see how parties are affected.

Your Answer

Question 4 (30 points)

Draw a plot of each party’s number of winnings, i.e. the number of regions where they got the most votes among all parties. Only consider the total votes’ rows.

Your Answer

Question 5 (30 points)

In this question you will be comparing the performances of top 4 parties, head to head.

Your Answer