Changeset 2975 for development
- Timestamp:
- May 25, 2006, 5:21:14 PM (19 years ago)
- Location:
- development/stochastic_study
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
development/stochastic_study/plot_spread.py
r2972 r2975 14 14 15 15 # Initialise 16 gauge _name =project.gauge_names[0]16 gauge = '%s.txt' %project.gauge_names[0] 17 17 number_of_realisations = project.number_of_realisations 18 18 … … 25 25 j = 0 # Count realisations 26 26 for filename in os.listdir('.'): 27 if filename.startswith(project.basename) and filename.endswith( '%s.txt' %gauge_name):27 if filename.startswith(project.basename) and filename.endswith(gauge): 28 28 if j < data.shape[1]: 29 29 print 'Reading filename %s (column %d)' %(filename, j) … … 51 51 for j in range(number_of_realisations): 52 52 #print j, data[:,j] 53 plot( data[:,j], 'k-')53 plot(time, data[:,j], 'k-') 54 54 55 raw_input('Next')56 55 xlabel('time(s)') 57 56 ylabel('stage (m)') 58 title('Realisation %d of %d' %(j, number_of_realisations)) 59 57 title('Realisation %d of %d' %(j, number_of_realisations-1)) 58 59 raw_input('Next') 60 60 61 61 62 … … 68 69 bins = create_bins(w, project.number_of_bins) 69 70 print 'bins', bins 70 hist = histogram(w, bins )71 print 'hist', hist71 hist = histogram(w, bins, relative=True) 72 #print 'hist', hist 72 73 73 74 #plot(w, 'k.') 74 plot( hist, 'k.')75 plot(bins, hist, 'k.') 75 76 xlabel('stage (m)') 76 ylabel(' count')77 ylabel('frequency') 77 78 title('Timestep %d of %d (t=%.2f)'\ 78 %(i, project.number_of_timesteps , time[i]))79 %(i, project.number_of_timesteps-1, time[i])) 79 80 raw_input('Next') 80 81 -
development/stochastic_study/project.py
r2972 r2975 19 19 20 20 # Stats (Suresh ?) 21 number_of_realisations = 121 number_of_realisations = 9 22 22 #std_dev = 0.0026 #Range is 26.035 cm 23 23 std_dev = 0.0013 #Range is 26.035 cm
Note: See TracChangeset
for help on using the changeset viewer.