diff --git a/Data/List/Unique.hs b/Data/List/Unique.hs
--- a/Data/List/Unique.hs
+++ b/Data/List/Unique.hs
@@ -28,7 +28,7 @@
 -- sortUniq "foo bar" == " abfor"
 
 sortUniq :: Ord a => [a] -> [a]
-sortUniq = nub . sort
+sortUniq = sort . nub
 
 filterByLength :: Ord a => (Int -> Bool) -> [a] -> [[a]]
 filterByLength p = filter (p . length) . group . sort
@@ -39,6 +39,13 @@
 
 repeated :: Ord a => [a] -> [a]
 repeated = map head . filterByLength (>1)
+
+-- | The repeatedBy function behaves just like repeated, except it uses a user-supplied equality predicate.
+-- 
+-- repeatedBy (>2) "This is the test line" == " eist"
+
+repeatedBy :: Ord a => (Int -> Bool) -> [a] -> [a]
+repeatedBy p = map head . filterByLength p
 
 -- | 'unique' gets only unique elements, that do not have duplicates.  
 -- It sorts them. Example: 
diff --git a/Unique.cabal b/Unique.cabal
--- a/Unique.cabal
+++ b/Unique.cabal
@@ -10,7 +10,7 @@
 -- PVP summary:      +-+------- breaking API changes
 --                   | | +----- non-breaking API additions
 --                   | | | +--- code changes with no API change
-version:             0.1.0.3
+version:             0.1.0.4
 
 -- A short (one-line) description of the package.
 synopsis:           It provides the functionality like unix "uniq" utility
