Contact
CoCalc Logo Icon
StoreFeaturesDocsShareSupport News AboutSign UpSign In
| Download

Missing Assignments

Views: 711
Kernel: Python 3 (Anaconda 5)
#Ex 19: import numpy as np data = np.loadtxt('FreefallData.txt', unpack = True) s = data[0,:]/1e2 t1 = data[1,:]/1e3 t2 = data[2,:]/1e3 t3 = data[3,:]/1e3 t4 = data[4,:]/1e3 t5 = data[5,:]/1e3 times = data[1:, 0:]/1e3 tmean = np.mean(times, axis = 0) tstd = np.std(times, axis = 0) np.savetxt('Freefall_V2.txt', np.c_[s, t1, t2, t3, t4, t5, tmean, tstd], fmt = '%5.5s', header='height [m] t1 t2 t3 t4 t5 tmean tstd [s]') np.savetxt('Freefall_V3.txt', np.c_[s, tmean, tstd], fmt = '%5.5s', header = 'height [m] tmean tstd [s]')