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 3 years ago.
Improve this question
Apriori algorithm is old and slow. Frequent pattern trees are much faster. However, I can't find frequent pattern tree libraries neither in R or in Python.
I'm sure they exists somewhere.
I'm not talking about home made code that can be found on the internet somewhere.
Does anyone know any Frequent Pattern Library?
FP-Growth is one algorithm which extracts frequent itemsets based on trees. For R please take a look here https://en.wikibooks.org/wiki/Data_Mining_Algorithms_In_R/Frequent_Pattern_Mining/The_FP-Growth_Algorithm. Same with Python. Just google FP-Growth and Python and pick a library which seems professional enough for your needs.
Take a look at this link and see if it provides what you need:
PyFIM - Frequent Item Set Mining for Python
Check out this pyfpgrowth.
This is a Python implementation of the Frequent Pattern Growth algorithm.
you can find the documentation here
Documentation
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'm looking for a fast way to count grammar errors in Python. For example, I need something along these lines:
matches = grammar_checker.check('You is awesome!')
assert len(matches) == 1
Speed is much more an issue than accuracy. I could live with a few false positives or negatives as a trade-off for fast checks. I am talking here about problem sizes on the order of 100k documents (with roughly 5-10k characters) in only a few minutes.
I came across LanguageTool in Java and its Python wrapper language_check. However, these are unfortunately too slow for my purposes. Any other suggestions or ideas? Thanks!
You should look How to check whether a sentence is correct (simple grammar check in Python)?
Also, you should use "grammar-check 1.3.1" module and works fast.
For more information, check out https://pypi.python.org/pypi/grammar-check/1.3.1
import grammar_check
tool = grammar_check.LanguageTool('en-GB')
text = 'This are bad.'
matches = tool.check(text)
len(matches)
>>>1
grammar_check.correct(text, matches)
>>>'These are bad'
You can try Grammarly, it is one of the most popular speller checkers.
Probably, they can provide some kind of an API.
(I am not an expert in Python frameworks but I guess you should try this if you need to just check grammar as fast as possible.
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 am trying to perform test summarize using self organizing map (SOM) as the clustering model. Do we have any libraries for performing SOM in python.
There is one here, but in general SOM implementations are not part of the main machine learning libraries. There are two reasons
SOM's, although nice to look at, don't really perform well in real problems.
It is too easy to construct one by yourself.
I would suggest to make it yourself. It is very easy and a great way to introduce yourself to python. The main code of the SOM itself is about 3 lines (a loop and one update). The remaing of the code would be for loading the data and plotting them, but you won't avoid that part of the code by using an external library
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 1 year ago.
Improve this question
I am currently looking at an implementation of the McGregor Maximum Subgraph in Python however I cannot seem to find an already implemented one.
I have found the algorithm implemented as part of the Boost C++ libraries however the Python bindings are missing.
This seem a bit odd? Is this the right algorithm to use? Are there any libraries out there which perform this task.
Check out the networkx package; I'm not sure if its networkx.algorithms.mis.maximal_independent_set is the same as the McGregor, but if you're working in networks, networkx is a useful package.
https://networkx.github.io/
The NetworkX implementation of ISMAGS does include the maximal subgraph problem.
https://networkx.org/documentation/stable/reference/algorithms/isomorphism.ismags.html
In addition, this implementation also provides an interface to find the largest common induced subgraph [2] between any two graphs, again taking symmetry into account.
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
I am looking for an API (preferably in python) that could be used to analyze complex networks. Basically I want to find things like:
Average shortest path,
Degree distribution
Giant Component
local clustering coefficient, global clustering coefficient etc..
Thanks
I would suggest Networkx and PyGraphViz. I've used them for a similar (but not as complex) graphing project in python and I love it.
The boost graph library has Python bindings.
I've used igraph on Linux. It started to grind on 64k nodes but that graph was becoming unwieldy any way.
Not sure about performance next to PyGraphViz but now you have a plenty of options.
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.
The community reviewed whether to reopen this question 1 year ago and left it closed:
Original close reason(s) were not resolved
Improve this question
Are there any python libraries for data trees?
I mean a tree as a general data structure, not just an xml tree.
(Like in this question, but in python.)
I'm happy with treelib. It addresses my problem. Could use a bit more documentation though. But the code is clear.
pypi, the Python Package Index, suggests tinytree, treedict, caxes, pyavl... these are just the top few after filtering away the many accidental hits (which point to specific tree such as XML ones, AST ones, etc, etc;-). If you clarify what you want to do with your trees it may be easier to suggest a specific package.
Although the ETE library seems to be originally developed to work with Phylogenetic trees, it implements many general features to work with any type of hierarchical tree structures, including programmatic tree drawing and visualization.
There is a comprehensive tutorial and a reference guide, in case you want to explore it.
python-graph seems to be a fairly thorough and complete package, and can export DOT graphs for use with Graphviz.
You probably want to look at cElementTree.