def add_limit(self, label='<STR_LIT>', **props):
if label not in self.leaf_labels:<EOL><INDENT>raise ValueError('<STR_LIT>'.format(label, self.leaf_labels))<EOL><DEDENT>for k,v in props.items():<EOL><INDENT>if k not in self.spec_props:<EOL><INDENT>raise ValueError('<STR_LIT>'.format(k, self.spec_props))<EOL><DEDENT>if len(v) != <NUM_LIT:2>:<EOL><INDENT>raise ValueError('<STR_LIT>'.format(k))<EOL><DEDENT><DEDENT>if label not in self.limits:<EOL><INDENT>self.limits[label] = {}<EOL><DEDENT>for k,v in props.items():<EOL><INDENT>vmin, vmax = v<EOL>if vmin is None:<EOL><INDENT>vmin = -np.inf<EOL><DEDENT>if vmax is None:<EOL><INDENT>vmax = np.inf<EOL><DEDENT>self.limits[label][k] = (vmin, vmax)<EOL><DEDENT>self._clear_cache()<EOL>
Define limits to spectroscopic property of particular stars.

        Usually will be used for 'logg', but 'Teff' and 'feh' will also work.

        In form (min, max): e.g., t.add_limit(logg=(3.0,None))

        None will be converted to (-)np.inf