@staticmethod
def get_data_attribute(data_obj, pydicom_attr, default=None, data_type=None):
    """
        Generic method to get the value of a pydicom dataset attribute
        :param data_obj: a pydicom dataset
        :param pydicom_attr: the attribute of interest
        :type pydicom_attr: str
        :param default: if attribute is not found, this value is returned
        :param data_type: set to 'float' or 'int' to convert return value as specified
        :type data_type: str
        :return: the value of the pydicom attribute
        """
    if hasattr(data_obj, pydicom_attr):
        value = getattr(data_obj, pydicom_attr)
        if data_type == 'float':
            return float(value)
        elif data_type == 'int':
            return int(float(value))
        return value
    return default
