Bars showing the measurement periods for oceanography data
1 visualizzazione (ultimi 30 giorni)
Mostra commenti meno recenti
Mina Masoud
il 2 Dic 2017
Commentato: Star Strider
il 3 Dic 2017
Hi Does anyone have code for plotting bar to show measurements periods as the same as pictures which I attached? Thank you in advance.
0 Commenti
Risposta accettata
Star Strider
il 2 Dic 2017
I do not know what your data are.
This works:
XData = sort(randi(9, 10, 2),2); % Create Data
YData = bsxfun(@times,ones(size(XData)),(1:size(XData,1))'); % Create Data
figure(1)
plot(XData', YData', 'LineWidth',2) % Note Transposed Matrices
axis([0 10 0 size(XData,1)+1])
Experiment with my code and your data to get the results you want.
2 Commenti
Più risposte (0)
Vedere anche
Categorie
Scopri di più su Bar Plots in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!