Conversation
| @@ -1,3 +1,12 @@ | |||
| # TextMining | |||
| To run this program you will need to download the GitHub repository as well as the Natural Language Toolkit (NKTL), the requests package and the Vader sentiment analysis package | |||
There was a problem hiding this comment.
There are just generally a few typos in this file, and this sentence is repeated at the bottom. I would suggest putting the lines that should go in the command line between `` because that's good markdown formatting. (ie: pip install vaderSentiment <= would look like => pip install vaderSentiment)
| mystring = mystring.replace('-', '') | ||
| mystring = mystring.replace('\"', '') | ||
| mystring = mystring.replace(',', '') | ||
| return mystring.lower() #makes everything lower case words like "The" and "the" are the same |
There was a problem hiding this comment.
There's a cleaner way to do this with a for loop. Make a list of all the characters you want to eliminate and iterate through that list rather than writing down every single character as a distinct line.
|
|
||
| """ | ||
|
|
||
| return( list(set(list(set(list1).intersection(list2))).intersection(list3))) |
There was a problem hiding this comment.
Minor detail, but there's probably a cleaner way to do this.
minebooks2.py
Outdated
| tragedies.append('Cymbeline.pickle') | ||
| histories = ['King_Henry_IV.pickle'] | ||
| histories.append('King_John.pickle') | ||
| histories.append('King_Richard_II.pickle') |
There was a problem hiding this comment.
I'm a little confused about why you appended these strings instead of just writing them out initially.
Do this:
tragedies = ['Antony_and_Cleopatra.pickle', 'Coriolanus.pickle', 'Cymbeline.pickle']
instead of:
tragedies = ['Antony_and_Cleopatra.pickle']
tragedies.append('Coriolanus.pickle')
tragedies.append('Cymbeline.pickle')
|
Overall, this was a good project! I made a few stylistic notes. There are some areas where you could have used loops instead of writing out things manually. Your documentation was really good and your variable naming was on point. Very minor detail, but you had a few typos in your comments/ReadMe. It's always good to reread and double check your wording. |
No description provided.