diff --git a/NLP/SwiftLDA.hs b/NLP/SwiftLDA.hs
--- a/NLP/SwiftLDA.hs
+++ b/NLP/SwiftLDA.hs
@@ -32,6 +32,7 @@
          -- * Querying finalized model
        , docTopicWeights
        , wordTopicWeights
+       , docCounts
        )
 where       
 -- Standard libraries  
@@ -102,6 +103,11 @@
   , exponent   :: !(Maybe Double)   -- ^ Learning rate exponent 
   }  deriving (Generic)
   
+-- | For each document sum the topic counts              
+docCounts :: Finalized -> Table1D
+docCounts = IntMap.map (sum . IntMap.elems) . docTopics
+  
+
 -- | Create transparent immutable object holding model information
 -- from opaque internal representation
 finalize :: LDA s -> ST s Finalized
diff --git a/swift-lda.cabal b/swift-lda.cabal
--- a/swift-lda.cabal
+++ b/swift-lda.cabal
@@ -1,5 +1,5 @@
 Name:                swift-lda
-Version:             0.4.0
+Version:             0.4.1
 Synopsis:            Online sampler for Latent Dirichlet Allocation
 Description:     Online Gibbs sampler for Latent Dirichlet Allocation. 
                  LDA is a generative admixture model frequently used 
