0

I need to compute information content from two Python lists. I understand that I can use the following formula where the probabilities are computed from the histograms of the list.

Information content = sum_ij p(x_i,y_j) log_2 ( p(x_i,y_j)/(p(x_i)p(y_j) ) / - sum_i p(y_i) log_2 p(y_i) .

Is there any built in Python API to compute information content? Thanks.

Omar Shehab
  • 1,004
  • 3
  • 14
  • 26

1 Answers1

1

Check out the information_content function in the biopython library: http://biopython.org/DIST/docs/tutorial/Tutorial.html#htoc303

Arya McCarthy
  • 8,554
  • 4
  • 34
  • 56