Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from scipy import stats
- from scipy.optimize import least_squares
- import matplotlib.pyplot as plt
- import numpy as np
- %matplotlib inline
- Counts = np.loadtxt('Counts.csv', delimiter = ',', unpack = True)
- # loads csv file as an array assigns columns to variables
- # Number of counts = 10
- AvgCounts = np.sum(Counts)/np.size(Counts)
- AvgCountsError = np.sqrt(AvgCounts)
- RateError = np.sqrt((AvgCountsError/AvgCounts)**2 + (timeError/time)**2)
- time = 60
- Rate = AvgCounts/time
- print(Rate, "+-", RateError)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement