diff --git a/Trajectories/plot_traj.py b/Trajectories/plot_traj.py index 40ea5228047652843c4f4e98b00e82a6e1c4c7c0..68dec85bdc2aaffcf80f901fe1c33e4f38aba692 100755 --- a/Trajectories/plot_traj.py +++ b/Trajectories/plot_traj.py @@ -33,6 +33,7 @@ src_crs = ccrs.PlateCarree() projection = ccrs.PlateCarree() fig, ax = plt.subplots(subplot_kw = {"projection": projection}) random.seed(0) +n_long_traj = 0 for traj in trajectories: duration = report_graph.node_to_date_eddy(traj[- 1], e_overestim, @@ -40,6 +41,7 @@ for traj in trajectories: - report_graph.node_to_date_eddy(traj[0], e_overestim, only_date = True) if duration >= 120: + n_long_traj += 1 xy = [] for node in traj: @@ -63,6 +65,7 @@ for traj in trajectories: ax.coastlines() ax.gridlines(draw_labels = True) +print("Number of trajectories with sufficient duration:", n_long_traj) if args.save: plt.savefig(f"plot_traj.{args.save}")