Q1
BarF <- gvisBarChart(APCQ1F[order(APCQ1F$TotalPer),], xvar="State" , yvar="TotalPer", options = list(title="Percent Enrolled vs State - Female",vAxis="{title:'State'}",hAxis="{title:'Percent'}", width=1000, height=1200))
plot(BarF)#plot(BarF)
BarB <- gvisBarChart(APCQ1B[order(APCQ1B$TotalPer),], xvar="State" , yvar="TotalPer", options = list(title="Percent Enrolled vs State - Black",vAxis="{title:'State'}",hAxis="{title:'Percent'}", width=1000, height=1200))
plot(BarB)#plot(Bar)
BarH <- gvisBarChart(APCQ1H[order(APCQ1H$TotalPer),], xvar="State" , yvar="TotalPer", options = list(title="Percent Enrolled vs State - Hispanic",vAxis="{title:'State'}",hAxis="{title:'Percent'}", width=1000, height=1200))
plot(BarH)#plot(Bar)
Q2
GeoStates <- gvisGeoChart(FemalePassRate[!is.na(FemalePassRate$Female.Pass.Rate),], "State", "Female.Pass.Rate",
options=list(title="Female Pass Rate", region="US", displayMode="regions", resolution="provinces",
width=600, height=400,colorAxis="{colors:['red','#fc8d62','#4daf4a']}"))
plot(GeoStates)
GeoStates <- gvisGeoChart(BlackPassRate[!is.na(BlackPassRate$Black.Pass.Rate),], "State", "Black.Pass.Rate",
options=list(region="US", displayMode="regions", resolution="provinces",
width=600, height=400,colorAxis="{colors:['red','#fc8d62','#4daf4a']}"))
plot(GeoStates)
GeoStates <- gvisGeoChart(HispanicPassRate[!is.na(HispanicPassRate$Hispanic.Pass.Rate),], "State", "Hispanic.Pass.Rate",
options=list(region="US", displayMode="regions", resolution="provinces",
width=600, height=400,colorAxis="{colors:['red','#fc8d62','#4daf4a']}"))
plot(GeoStates)
Q3
APCQ3Fnew=APCQ3F[!is.na(APCQ3F$Ratio),]
BarF3 <- gvisBarChart(APCQ3Fnew[order(APCQ3Fnew$Ratio),], xvar="State" , yvar="Ratio", options = list(title="Pass Ratio: Female vs Total",vAxis="{title:'State'}",hAxis="{title:'Ratio'}",height=1000,width=600))
plot(BarF3)#plot(BarF3)
APCQ3Bnew=APCQ3B[!is.na(APCQ3B$Ratio),]
BarB3 <- gvisBarChart(APCQ3Bnew[order(APCQ3Bnew$Ratio),], xvar="State" , yvar="Ratio", options = list(title="Pass Ratio: Blacks vs Total",vAxis="{title:'State'}",hAxis="{title:'Ratio'}",height=1000,width=600))
plot(BarB3)#plot(BarB3)
APCQ3Hnew=APCQ3H[!is.na(APCQ3H$Ratio),]
BarH3 <- gvisBarChart(APCQ3Hnew[order(APCQ3Hnew$Ratio),], xvar="State" , yvar="Ratio", options = list(title="Pass Ratio: Hispanics vs Total",vAxis="{title:'State'}",hAxis="{title:'Ratio'}",height=1000,width=600))
plot(BarH3)#plot(BarH3)