listfile = local_path + '/phd/ownCloud/data/Regions/MetalEarth/malartic/j2/mal_amt.lst' dataset = WSDS.Dataset(listfile=listfile) dataset.remove_sites(sites='MAL062A') dataset.sort_sites('south-north') data = dataset.data # data = WSDS.Data(datafile='C:/Users/eric/phd/Kilauea/stitched/1_day/Z/Kilauea_may_daily.data') days = (501, 530) hour_or_day = 1 # sets the interval in labels, so choose appropriately n_interp = 300 cax_rho = [0, 4] # data = WSDS.Data(datafile=datafile) # rmsites = [site for site in data.site_names if site[0] == 'e' or site[0] == 'd'] # data.remove_sites(rmsites) # data.sort_sites(order='west-east') rho = {site.name: utils.compute_rho(site)[0] for site in data.sites.values()} pha = {site.name: utils.geotools_filter(np.log10(site.periods), utils.compute_phase(site, 'xy')[0], 0.8, 1) for site in data.sites.values()} # pha = {site.name: utils.compute_phase(site)[0] for site in data.sites.values()} bost = {site.name: utils.compute_bost1D(site)[0] for site in data.sites.values()} depths = {site.name: utils.compute_bost1D(site)[1] for site in data.sites.values()} periods = [] loc = [] rhovals = [] phavals = [] depth_vals = [] bostvals = [] for jj, site in enumerate(data.site_names): for ii, p in enumerate(data.sites[site].periods): periods.append(p) bostvals.append(bost[site][ii]) depth_vals.append(depths[site][ii]) rhovals.append(rho[site][ii])
# datafile = 'C:/Users/eric/Documents/MATLAB/MATLAB/Inversion/Regions/MetalEarth/swayze/swz_cull1/swz_cull1f_Z.dat' datafile = 'C:/Users/eric/phd/ownCloud/data/Regions/MetalEarth/j2/cull_allSuperior.data' listfile = 'C:/Users/eric/phd/ownCloud/data/Regions/MetalEarth/j2/culled_allSuperior.lst' data = WSDS.Data(datafile=datafile, listfile=listfile) raw = WSDS.RawData(listfile=listfile) raw.locations = raw.get_locs(mode='latlong') for ii in range(len(raw.locations)): lon, lat = utils.project((raw.locations[ii, 1], raw.locations[ii, 0]), zone=16, letter='U')[2:] raw.locations[ii, 1], raw.locations[ii, 0] = lon, lat data.locations = raw.locations save_path = 'C:/Users/eric/phd/ownCloud/Documents/Seminars/Seminar 3/Figures/Pseudosections/culled/' # rmsites = [site for site in data.site_names if site[0] == 'e' or site[0] == 'd'] # data.remove_sites(rmsites) # data.sort_sites(order='west-east') rho = {site.name: utils.compute_rho(site)[0] for site in data.sites.values()} pha = {site.name: utils.compute_phase(site)[0] for site in data.sites.values()} rho_lim = [0, 5] n_interp = 250 period = 14 padding = 50000 # bost = {site.name: utils.compute_bost1D(site)[0] for site in data.sites.values()} # depths = {site.name: utils.compute_bost1D(site)[1] for site in data.sites.values()} rho_error_tol = 0.5 phase_error_tol = 10 for idx, period in enumerate(data.periods): loc_x = [] loc_y = [] rho_vals = [] phase_vals = [] loc_z = []
fig = plt.figure(figsize=(12, 6)) axes.append(plt.subplot2grid((3, 2), (0, 0), rowspan=2)) axes.append(plt.subplot2grid((3, 2), (2, 0), rowspan=1)) axes.append(plt.subplot2grid((3, 2), (0, 1), rowspan=2)) axes.append(plt.subplot2grid((3, 2), (2, 1), rowspan=1)) # site = data.sites[sites[0]] for ii, name in enumerate(sites): site = data.sites[name] rhoxy, rhoxy_err, rhoxy_log10err = utils.compute_rho(site, calc_comp='rhoxy', errtype='errors') rhoyx, rhoyx_err, rhoyx_log10err = utils.compute_rho(site, calc_comp='rhoyx', errtype='errors') phaxy, phaxy_err = utils.compute_phase(site, calc_comp='phaxy', wrap=True, errtype='errors')[:2] phayx, phayx_err = utils.compute_phase(site, calc_comp='phayx', wrap=True, errtype='errors')[:2] axes[(ii) * 2].errorbar(np.log10(site.periods), np.log10(rhoxy), xerr=None, yerr=rhoxy_log10err, marker='o', linestyle='', color='b', markersize=5, label='XY') axes[(ii) * 2].errorbar(np.log10(site.periods),