Contents
scikit-rf can be used to calculate uncertainty estimates given a set of networks. The NetworkSet object holds sets of networks and provides automated methods for calculating and displaying uncertainty bounds.
Although the uncertainty esimation functions operate on any set of networks, the topic of uncertianty estimation is frequently associated with calibration uncertianty. That is, how certain can one be in results of a calibrated measurement.
Assume that numerous touchstone files, representing redudant measurements of a single network are made, such as:
In [24]: ls *ro*
ro,0.s1p ro,1.s1p ro,2.s1p ro,3.s1p ro,4.s1p ro,5.s1p
In case you are curious, the network in this example is an open rectangular waveguide radiating into freespace. The numerous touchstone files ro,0.s1p , ro,1.s1p, ... , are redundant measurements on which we would like to calculate the mean response, with uncertainty bounds.
This is most easily done by constructing NetworkSet object. The fastest way to achieve this is to use the convenience function load_all_touchstones(), which returns a dictionary with Network objects for values.
import pylab
import skrf as rf
ro_set = rf.NetworkSet(\
rf.load_all_touchstones('.',contains='ro').values(),\
name = 'Radiating Open')
pylab.figure()
pylab.title('Uncertainty in Phase')
ro_set.plot_uncertainty_bounds_s_deg()
pylab.figure()
pylab.title('Uncertainty in Magnitude')
ro_set.plot_uncertainty_bounds_s_db()
pylab.show()