repo.or.cz
/
wrf-fire-matlab.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
history
|
raw
|
HEAD
Merge branch 'fixf'
[wrf-fire-matlab.git]
/
cycling
/
plot_grans.m
blob
a6afc80e05350fef1b2ed8d7a5e73b3bba655cf0
1
function plot_grans(g)
2
3
n = length(g);
4
b = g(1).time;
5
figure
6
for i = 2:n
7
t1 = g(i-1).time - b;
8
t2 = g(i).time -b;
9
if mod(i,2)
10
c = 'green';
11
else
12
c = 'red';
13
end
14
x = [0 n n 0];
15
y = [t1 t1 t2 t2];
16
hold on
17
patch(x,y,c)
18
19
end