This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
n1 = NewData[['bathrooms','bedrooms','price',"By Owner", | |
"Exclusive", | |
"Sublet / Lease-Break", | |
"No Fee", | |
"Reduced Fee", | |
"Short Term Allowed", | |
"Furnished", | |
"Laundry In Unit", | |
"Private Outdoor Space", | |
"Parking Space", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
wikiD = map(lambda x: TextBlob(x),DataWithRating3.Review) | |
resultD=[] | |
for i in range(len(wikiD)): | |
k = wikiD[i].sentiment.polarity | |
resultD.append(k) | |
DataWithRating3['Polarity'] = resultD | |
import seaborn as sns |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
wikiC = map(lambda x: TextBlob(x),DataWithRating2.Review) | |
resultC=[] | |
for i in range(len(wikiC)): | |
k = wikiC[i].sentiment.polarity | |
resultC.append(k) | |
DataWithRating2['Polarity'] = resultC | |
import seaborn as sns |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
wikiB = map(lambda x: TextBlob(x),DataWithRating1.Review) | |
resultB=[] | |
for i in range(len(wikiB)): | |
k = wikiB[i].sentiment.polarity | |
resultB.append(k) | |
DataWithRating1['Polarity'] = resultB |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sys | |
import numpy as np | |
reload(sys) | |
sys.setdefaultencoding('utf8') | |
from textblob import TextBlob | |
wikiA = map(lambda x: TextBlob(x),DataWithRating.Review) | |
resultA=[] | |
for i in range(len(wikiA)): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
result1=[] | |
for i in range(len(wiki)): | |
objective = wiki[i].sentiment.subjectivity | |
result1.append(objective) | |
result3=[] | |
for i in range(len(wiki1)): | |
objective = wiki1[i].sentiment.subjectivity | |
result3.append(objective) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Polarity for Gabapentin | |
import sys | |
reload(sys) | |
sys.setdefaultencoding('utf8') | |
from textblob import TextBlob | |
wiki = map(lambda x: TextBlob(x),B.Review) | |
result=[] | |
for i in range(len(wiki)): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from os import path | |
import PIL | |
import matplotlib.pyplot as plt | |
from wordcloud import WordCloud | |
n = Pregabalin.Review.str.cat(sep=', ') | |
wordcloud = WordCloud().generate(n) | |
# Open a plot of the generated image. | |
plt.imshow(wordcloud) | |
plt.axis("off"); | |
plt.show() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
n = Topiramate.Review.str.cat(sep=', ') | |
wordcloud = WordCloud().generate(n) | |
# Open a plot of the generated image. | |
plt.imshow(wordcloud) | |
plt.axis("off"); | |
plt.show() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
k = clonazepam.Review.str.cat(sep=', ') | |
wordcloud = WordCloud().generate(k) | |
# Open a plot of the generated image. | |
plt.imshow(wordcloud) | |
plt.axis("off"); | |
plt.show() |
NewerOlder