How to create a 2D waterfall plot?

13 次查看(过去 30 天)
I would like to create a 2D spectral density waterfall plot. I imagine it would be easier to use the waterfall function somehow or even to create my own code for it by somehow using the waterfall function to create an array which displays horizontally along the y-axis, and then either shifting that row down or just plotting the new row under it. Is there a way to save the waterfall data into an array? Or a way to plot the new waterfall data with an offset on the y-axis?
the waterfall data is an array called 'sweepData' which is updated in a loop which I would like to be appended to the waterfall graph in each loop
Attached is a picture with 1 plot of the waterfall data, I just need to keep plotting the new data under it
Code:
subplot(3,1,3)
spec_dens = waterfall(sweepData);
xlabel('Frequency (MHz)')
ylabel('Sample Number')
title('Waterfall (Spectral Density Graph)')
view(0,90)
xlim([0 numSamples])
ylim([0 numCapture])
set(gca,'Ydir','reverse')
  1 个评论
Veronica yep
Veronica yep 2017-6-27
sorry i should say, the data, 'sweepData' which is used in the waterfall function is just an array of power values of corresponding frequencies

请先登录,再进行评论。

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Annotations 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by