def tracktype(self, tracktype):
        """
        When setting the track type, the valid parameters for this track type
        need to be set as well.
        """
        self._tracktype = tracktype
        if tracktype is not None:
            if 'bed' in tracktype.lower():
                tracktype = 'bigBed'
            elif 'wig' in tracktype.lower():
                tracktype = 'bigWig'
        self.params.update(constants.track_typespecific_fields[tracktype])