Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 8 years ago.
Improve this question
I am going to start a project on Markov Decision Processes and am starting up a basic framework to work in. The first thing I want to set up is a grid of n by n, with cells which are empty or occupied by some class of agents (lets say a monkey, banana and palm tree). I want to be able to visualize this with JAVA. But am actually hoping that I will not have to write the code from scratch, i.e. the visualization part.
So, a grid of n by n, with (possible) some word, picture or number in each cell. Any ideas on existing packages?
I think you can use a JTable
http://docs.oracle.com/javase/7/docs/api/javax/swing/JTable.html
http://docs.oracle.com/javase/tutorial/uiswing/components/table.html
Setting the appropiate TableCellRenderer you can display each cell the way you like.
The problem is that you have to write some code.
Related
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 5 years ago.
Improve this question
I am trying to implement a application to recognized human facial expressions(happiness,sadness,boring, etc,) then after automatically selecting a song which suitable for current emotion of the person, if he is sad system playing enjoyable song, how can i do this thing, if any API's already have? any examples for me?
According to my understanding,your core need is facial expression recognition.there is an API ready for you ,emotion API by Microsoft https://azure.microsoft.com/zh-cn/services/cognitive-services/emotion/.Which Can detect emotions including anger, contempt, disgust, fear, happiness, neutral, sadness and surprise. You can think of these emotions across cultural boundaries, usually by certain facial expressions.
example:you can refer to How-old, a popular APP which Can measure the characters of age and Gender through photos.the different is:it's a light application Supported by another Microsoft API(Project Oxford),But I think you can get some inspiration from it.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 6 years ago.
Improve this question
I have a hashtable that contains the information about some book titles and the number of times each book is purchased. I want to draw a bar chart that can show this information visually. Is there any library or method in java that can do this?
HashTable<String, Integer> bookPurchaseTable=new HashTable<String, Integer>();
JavaFX has bar chart capabilities. This page has a tutorial that should have enough information to get you started.
https://docs.oracle.com/javafx/2/charts/bar-chart.htm
Also, You should probably use a HashMap instead of a HashTable if possible.
Use myHashMap.keySet() to get the keys, and then for each key, use myHashMap.get(key) to get the integer.
it's a big topic about Java UI deployment.
you can try java swing tutorial first, and learn how to develop UI in java.
BTW, it's recommend to use HashMap not HashTable now.
hope you can enjoy the Java.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 6 years ago.
Improve this question
I want to use libdx and box2d, what things I can simulate with box2d or libgdx and I need something that can be useful in everyday life, it can be on any platform thanks.
You can simulate the effect of gravity on objects having different shapes and mass. You could allow the user to place objects and make the user specify the shape, mass ans size. then the user can watch as gravity causes the shapes to move in interesting patterns.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 4 years ago.
Improve this question
Where can I find more information on how exactly the following method works
and what it actually does? I found the single line of the documentation leaves a bit to be desired:
Class weka.associations.Apriori
public void buildAssociations(Instances instances) throws Exception
Method that generates all large itemsets with a minimum support, and from these all association rules with a minimum confidence.
Look at all the documentation, not only the method documentation tooltip in your IDE. You are missing out on a lot of the documentation.
Weka comes with a whole book, that will give you plenty of detail.
The Apriori class documentation also contains much more than that single line you quoted. You failed to access the JavaDoc class documentation; it's not the documentation that "leaves a bit to be desired", is it? It points to two publication giving the details on the algorithm.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 2 years ago.
Improve this question
I have a list of words in a text file. What I want is for an input word a list of words that are similar to the input word. So the program should work similar to a spell checker API with only thing that the dictionary is limited to my list of words.
I can write my own code if I get some pointers to Spell Checker algorithm or regular expressions.
Take a look at Apache Commons Lang StringUtils.getLevenshteinDistance. The Levenshtein algorithm gives the "edit distance" between two words, that is, how similar they are. Their implementation is quite fast - I tested it against another implementation I found online and it was about 1/3 faster if I remember correctly.
I highly recommend taking a look at Peter Norvig's article on How to Write a Spelling Corrector. It's worth reading. And it doesn't involve too much of a complexity. If you scroll down the page, you can see links to Java implementations. Then, you can customize it to your own needs.
http://en.wikipedia.org/wiki/Levenshtein_distance