Plot single vector from 3D array
41 次查看(过去 30 天)
显示 更早的评论
I have a 5x5x150 3d array where I am saving a time series of correlations between variables. At the end of my code I'm attempting to plot the time series correlation between two variables with a command like plot(MyVar(1,1,:)). I get the error message that my data cannot have more than two dimensions because obviously MyVar(1,1,:) = a 1x1x150 3d Matrix. In that same command, how can I concatenate that command into a single vector so that it can be utilized by the plot command? The end value being plotted should by a 150x1 vector.
Hopefully my intention here is clear and thanks in advance for the help, Brian
2 个评论
Sara
2015-1-15
It's better if you post the exact error matlab gives you. Try this:
plot(squeeze(MyVar(1,1,:)))
采纳的回答
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Logical 的更多信息
产品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!