Cell #6: Some of the questions asked students to rank from 1-7, where 1 would be least positive, and 7 the most positive. Therefore, the code sets up that if a particular question is known to be in the reverse order where 1 corresponded to the most positive, the python code will automatically switch a 1 to a 7, switching a 2 to a 6, 3 to a 5, a 4 will remain a 4, and so on, just replacing the values with their opposites in the bounds of 1-7. The questions that were in the correct order from the first sentence, are left untouched, only the flipped ones are adjusted. iloc --> works on positions in the data (integer locations only) _________________________________________________________________________________ Cell #7 Going through each year's survey to find the specific questions that have flipped ranking from 1-7, then finding the corresponding column in the excel data for the survey to identify the columns that need to undergo the python code that will reverse the val...
Comments
Post a Comment