I have a laser that is sent through a signal splitter. 90% of the light goes into a diffuser and that is detected by a Photomultiplier tube (PMT). The other 10% of the signal goes to a separate silicon photodiode that is used to monitor the power of the laser during diffuser testing. The diffuser is rotated through a range of -60° to +60° and stops every 3° to record the area of the optical signal from both the PMT and the photodiode (this is referred to as one scan). The data recorded by the photodiode is used to normalize the area of the PMT like this:
angle1 = np.array(PMT1[0]), area1 = np.array(PMT[1])
p1 = np.array(diode1[1]), `area1_norm = area1 * 0.01 / p1
The data is in terms of (x,y) = ([angle], [area]). I want to calculate the average and the standard deviation for the normalized PMT area at each angular position of the diffuser. So say for three sets of photodiode areas:
PMT1 = ([-60,-57,-54,-51,-48,-45,-42,-39,-36,-33,-30,-27,-24,-21,-18,-15,-12,-9,-6,-3,0,3,6,9,12,15,18,21,24,27,30,33,36,39,42,45,48,51,54,57,60],[7.099,7.317,7.543,7.811,7.955,8.194,8.292,8.558,8.862,8.906,9.166,9.265,9.354,9.641,9.748,9.856,9.906,9.805,9.936,9.950,9.892,9.944,9.867,9.808,9.696,9.732,9.624,9.480,9.389,9.244,9.187,8.955,8.673,8.538,8.227,8.161,7.966,7.679,7.442,7.307,7.017])
diode1 = ([-60,-57,-54,-51,-48,-45,-42,-39,-36,-33,-30,-27,-24,-21,-18,-15,-12,-9,-6,-3,0,3,6,9,12,15,18,21,24,27,30,33,36,39,42,45,48,51,54,57,60],[0.01011,0.01007,0.01013,0.01005,0.01014,0.01018,0.01013,0.01021,0.01020,0.01020,0.01019,0.01028,0.01021,0.01026,0.01025,0.01020,0.01024,0.01029,0.01019,0.01023,0.01027,0.01019,0.01031,0.01030,0.01031,0.01034,0.01021,0.01019,0.01019,0.01025,0.01034,0.01020,0.01024,0.01029,0.01011,0.01013,0.01025,0.01013,0.01025,0.01004,0.01003])
PMT2 = ([-60,-57,-54,-51,-48,-45,-42,-39,-36,-33,-30,-27,-24,-21,-18,-15,-12,-9,-6,-3,0,3,6,9,12,15,18,21,24,27,30,33,36,39,42,45,48,51,54,57,60],([6.947,7.196,7.376,7.610,7.853,8.096,8.299,8.410,8.567,8.702,8.896,9.1429.425,9.400,9.527,9.654,9.614,9.870,9.943,9.998,10.05,9.969,9.951,9.957,9.828,9.803.9.629,9.419,9.313,9.170,9.084,8.885,8.793,8.513,8.328,8.130,7.939,7.677,7.431,7.184,6.905])
diode2 = ([-60,-57,-54,-51,-48,-45,-42,-39,-36,-33,-30,-27,-24,-21,-18,-15,-12,-9,-6,-3,0,3,6,9,12,15,18,21,24,27,30,33,36,39,42,45,48,51,54,57,60],[0.01016,0.01004,0.01019,0.01023,0.01018,0.01022,0.01036,0.01027,0.01023,0.01034,0.01033,0.01026,0.01028,0.01040,0.01035,0.01034,0.01032,0.01039,0.01021,0.01036,0.01035,0.01025,0.01024,0.01035,0.01034,0.01030,0.01028,0.01038,0.01020,0.01024,0.01028,0.01017,0.01014,0.01025,0.01022,0.01025,0.01022,0.01025,0.01022,0.01025,0.01021])
PMT3 = ([-60,-57,-54,-51,-48,-45,-42,-39,-36,-33,-30,-27,-24,-21,-18,-15,-12,-9,-6,-3,0,3,6,9,12,15,18,21,24,27,30,33,36,39,42,45,48,51,54,57,60],[7.116,7.364,7.668,7.868,8.011,8.321,8.567,8.699,8.876,9.154,9.346,9.591,9.524,9.744,9.969,9.989,10.08,10.20,10.16,10.13,10.19,10.11,10.03,10.03,9.936,9.732,9.655,9.492,9.305,9.245,9.120,8.877,8.833,8.635,8.470,8.217,7.980,7.844,7.534,7.336,6.966])
diode3 = ([-60,-57,-54,-51,-48,-45,-42,-39,-36,-33,-30,-27,-24,-21,-18,-15,-12,-9,-6,-3,0,3,6,9,12,15,18,21,24,27,30,33,36,39,42,45,48,51,54,57,60],[0.01016,0.01004,0.01019,0.01023,0.01018,0.01022,0.01036,0.01027,0.01023,0.01034,0.01033,0.01026,0.01028,0.01040,0.01035,0.01034,0.01032,0.01039,0.01021,0.01036,0.01035,0.01025,0.01024,0.01035,0.01034,0.01030,0.01028,0.01038,0.01020,0.01024,0.01028,0.01017,0.01014,0.01025,0.01022,0.01025,0.01022,0.01025,0.01022,0.01025,0.01021,0.01006,0.01021,001020,0.01012])
I would use diode1 data to normalize the y values in PMT1 and so forth. The x values are the same for each data set because they're just repeated scans. I am interested in calculating the average and standard deviation for the y values (for the PMT) at each corresponding x angle. So for each angle, I should have one value for the average normalized PMT area and one value for the standard deviation of the normalized PMT area. I hope that makes sense and thank you in advance for the help!