Heyang Gong
12/27/2015
My shiny app is to predict whether the person is a democratic or republican, click prediction of democratic or republican to see the application. It includes 3 ways of prediction.
The republicans usually have higher IQ, So we predict the person is a republic when he/she has a IQ of 120 otherwise democratic.
id<- function(id1) {
if (id1==80) {"Democratic"}
else {"Republican"}
}
id(120)
[1] "Republican"
# prediction of democratic or republican
Republicans are often likes Donald Trump while democratics hate him so much. So we make a prediction on whether the person likes Donald Trump or not.
Here is introduction of Donald Trump
Democratics are usuall young idealistic students, or losers who needed the government to be a babysitter. So age is one of predictor for their political believes.