Returns or sets the weight formula of the spectrum given by spectrum_index. If the spectrum object is an ellipsometry object you have to set subindex to 1 to refer to the weight_formula for psi. Using a value of 2 for subindex selects the weight formula for delta.