Merge branch 'femwind-inv3-fix' into femwind
[wrf-fire-matlab.git] / cycling / plot_paths3d.m
blob6c9e48497db2f8b07867a05c0584d95718a1ef0f
1 function plot_paths3d(path_struct,fig_num)
2 %input path_sruct = graph_dets(w,cull)
3 %      fig_num - figure to draw on       
4 %fg = path_struct.graph;
5 t0 = path_struct.red.start_datenum;
6 pts = path_struct.points(:,1:3);
7 pts(:,3) = pts(:,3)-t0;
8 pts(:,1:2) = path_struct.grid_pts;
9 %pts(:,3) = (pts(:,3)-floor(min(pts(:,3))));
10 paths = path_struct.paths;
11 figure(fig_num)
12 hold on
15 for j = 1:length(paths)%length(pts)
16     %c = sqrt(path_struct.paths(j).c/100);
17     plot3(pts(paths(j).p,2),pts(paths(j).p,1),pts(paths(j).p,3),'g');
18     %plot3(pts(paths(j).p,2),pts(paths(j).p,1),pts(paths(j).p,3));
19 end
20 scatter3(pts(:,2),pts(:,1),pts(:,3),'*r')
21 hold off
22 grid on,xlabel('Lon'),ylabel('Lat'),zlabel('Time [days]')
23 title('Shortest Paths and Active Fire Detections')
24 end