How to do a line plot with four variables?

2 次查看(过去 30 天)
I have four variables in excel sheet , time, temp, lat and lon. I have to plot temperature data (which is on different grids i.e. lat, lon as in excel sheet). I want to take number of grids longitude 1 to 144 and latitude 1 to 73. And on this grid I have to plot temp data. I am not so perfect in MATLab. I have tried a lot but I am not getting how to do it. I've tried some commands like geoshow, load topo, m_map , but not succeeded. Kindly, help me. I've attached the excel sheet with this.
Thanks and Regards

采纳的回答

Image Analyst
Image Analyst 2015-8-15
I'm not sure how you want to handle the year (column 1), but this is what I have so far:
[numbers, txt, raw] = xlsread('book1.xls');
temp = numbers(:, 2);
x = numbers(:, 3);
y = numbers(:, 4);
% Create an image
myTempImage = zeros(max(y), max(x));
for row = 1 : length(x)
% Assign temperature at row y, column x:
myTempImage(y(row), x(row)) = temp(row);
end
imshow(myTempImage, [], 'InitialMagnification', 1600);
axis on;
myColorMap = jet(256);
myColorMap(1,:) = [0,0,0];
colormap(myColorMap);
colorbar;
  1 个评论
Gargi
Gargi 2015-8-15
Thanku...its working....no problem...will try to do how to show years in plot....thanks a lot....!!

请先登录,再进行评论。

更多回答(0 个)

类别

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

Community Treasure Hunt

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

Start Hunting!

Translated by