You might try delattr(ds, unwanted_attribute), though I'm not certain
if that will work on Dataset objects. del ds[unwanted_attribute] might
also work, not sure.
Aside, you can also structure the loop like so:
for unwanted_attribute in unwanted_attributes:
And skip the len/range/[x] parts.
> --
> You received this message because you are subscribed to the Google Groups
> "pydicom" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to
pydicom+u...@googlegroups.com.
> To post to this group, send email to
pyd...@googlegroups.com.
> Visit this group at
http://groups.google.com/group/pydicom.
> For more options, visit
https://groups.google.com/d/optout.