diff --git a/lib/dicom/DObject.rb b/lib/dicom/DObject.rb
index <HASH>..<HASH> 100644
--- a/lib/dicom/DObject.rb
+++ b/lib/dicom/DObject.rb
@@ -880,14 +880,9 @@ module DICOM
 

     # Removes all private data elements from the DICOM object.
     def remove_private
-      # Private data elemements have a group tag that is odd.
-      odd_group = ["1,","3,","5,","7,","9,","B,","D,","F,"]
-      odd_group.each do |odd|
-        positions = get_pos(odd, :partial => true)
-        # Delete all entries (important to do this in reverse order).
-        positions.reverse.each do |pos|
-          remove(pos)
-        end
+      # Private data elemements have a group tag that is odd. This is checked with the private? String method.

+      (0...@tags.length).reverse_each do |pos|

+        remove(pos) if @tags[pos].private?

       end
     end
Simplified the remove_private method in the DObject class.