We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
also tried to load List
List<String> texts = new ArrayList<>(); BufferedReader br = new BufferedReader(new FileReader("c:\\c\\temp.txt")); String line = null; while((line = br.readLine())!=null){ texts.add(line); // System.out.println(new String(line.getBytes(), "UTF-8")); } br.close(); final FrequencyAnalyzer frequencyAnalyzer = new FrequencyAnalyzer(); frequencyAnalyzer.setWordFrequenciesToReturn(600); frequencyAnalyzer.setMinWordLength(2); frequencyAnalyzer.setWordTokenizer(new ChineseWordTokenizer()); final List<WordFrequency> wordFrequencies = frequencyAnalyzer.load(texts); final Dimension dimension = new Dimension(600, 600); final WordCloud wordCloud = new WordCloud(dimension, CollisionMode.PIXEL_PERFECT); wordCloud.setPadding(2); wordCloud.setBackground(new CircleBackground(300)); wordCloud.setColorPalette(new ColorPalette(new Color(0xD5CFFA), new Color(0xBBB1FA), new Color(0x9A8CF5), new Color(0x806EF5))); wordCloud.setFontScalar(new SqrtFontScalar(12, 45)); wordCloud.build(wordFrequencies); wordCloud.writeToFile("c:\\c\\temp.png");
The text was updated successfully, but these errors were encountered:
Can you upload a picture of the resulting image? I can't tell the problem from only this code. Also, if possible, post temp.txt as well. Thanks
Sorry, something went wrong.
No branches or pull requests
also tried to load List
The text was updated successfully, but these errors were encountered: