'How to use word cloud in Arabic language datasets
I have a sum problem when I use this code in my data set
enter code here
from bidi.algorithm import get_display
import os
import matplotlib.pyplot as plt
from wordcloud import WordCloud
os.chdir("C:")
f = open('example.txt', 'r', encoding = 'utf-8')
data = arabic_reshaper.reshape(f.read())
WordCloud = WordCloud(font_path='arial',background_color='white',
mode='RGB',width=2000,height=1000).generate(data)
plt.title("wordcloud")
plt.imshow(WordCloud)
plt.axis("off")
plt.show()
I don't know how to use it with my data set
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
