6/26/17 Notes (Case sensitivity not working)
-
Added column names for the Attitudes Survey for all years.
-
Working on getting the sequence matcher to work, with Torri
-
Here is the example Dr. McColgan gave me:
-
>>> from difflib import SequenceMatcher as SM
>>> s1 = ' It was a dark and stormy night. I was all alone sitting on a red chair. I was not completely alone as I had three cats.'
>>> s2 = ' It was a murky and stormy night. I was all alone sitting on a crimson chair. I was not completely alone as I had three felines.'
>>> SM(None, s1, s2).ratio()
0.9112903225806451
-
Here is what I typed to work with my files/code:
-
s1 = CareerS14['Full Name']
s2 = ConfidenceS14['Full Name']
SM(None,s1,s2,).ratio()
-
This gave me a number, but I think it compared the ENTIRE column instead of the individual rows.
-
Added code the code Torri used to change all letters in the full name to capital letters
-
This works for all file except for the attendance file.
-
I double checked to make sure I made a “Full Name Column” in the attendance file, then put the code for attendance in its own cell and it’s still not working
-
I tried writing the code so that it made the “First Name,” and “Last Name” columns all upper case, instead of just the “Full Name” column. This did not work.
-
I tried restarting Kernel and clearing outputs, then running the cells again. This did not work.
-
I tried shutting the code down then opening it up again. This did not work.
Comments
Post a Comment