python - How to find similarities in matrix? -


I have a huge matrix (10 * 10k) I want to know whether similarities can be found between the lines.

Example of the matrix: 4 * 5

  col1 col2 col3 col4 0 1 2 3 4 5 2 3 2 3 0 0.1 1 0 0 0 1 0   

I want to know that there is no statistical theory to determine the similarities between the data.

Line 1 is like 100% Line 3 line 2 like 50% line 3

But how can I deal with each other with numbers?

Near line 4 and line 5 - Near-equal value How can we find the way to calculate the probability of equality? Is there a function on Python, zero, science-learned that is calculated?

  Import numpy mat = numpy.random.random (30, 30)) def find_similarities (line, target_line):    

equality measures parity function . Or calculating between each line will solve your problem. By optimizing this idea according to your needs, you can also benefit from the Heming distance or the Jackcard index. You can do this in the O (n) time and O (1) space Can calculate the similarities of

Comments

Post a Comment

Popular posts from this blog

jasper reports - How to center align barcode using jasperreports and barcode4j -

Verilog Error: output or inout port "Q" must be connected to a structural net expression -

c# - ASP.NET MVC - Attaching an entity of type 'MODELNAME' failed because another entity of the same type already has the same primary key value -