[問題] colorbar error已回收

看板MATLAB作者 (ForeverFun)時間14年前 (2010/04/22 15:43), 編輯推噓0(002)
留言2則, 2人參與, 最新討論串1/1
請問一下~~ 我在畫colormap當中 程式如下~~ % Colormap ColorMap_Reverse=[1 1 1 1 1 1 1 1 1 0.85 0.85 0.85 0.8 0.8 0.8 0.75 0.75 0.75 0.7 0.7 0.7 0.65 0.65 0.65 0.6 0.6 0.6 0.55 0.55 0.55 0.5 0.5 0.5 0.45 0.45 0.45 0.4 0.4 0.4 0.35 0.35 0.35 0.3 0.3 0.3 0.25 0.25 0.25 0.2 0.2 0.2 0.15 0.15 0.15 0 0 0]; figure('Colormap',ColorMap_Reverse) axis equal for H=1:4; subplot(2,2,H) Con=strcat('contourf(X_axis,Y_axis,XY_Density_Percentage',num2str(H),',''EdgeColor''',','' none'')'); eval(Con); % text(0,0,'▲'); text(0,67,'◎'); text(0,134,'◎'); text(0,201,'◎'); text(67,0,'◎'); text(134,0,'◎'); text(201,0,'◎'); % caxis([0.1 0.4]); colorbar; colormap; xlabel('X (m)'); ylabel('Y (m)'); axis square end ================================程式結束========================== 這樣可以跑出結果 但是我把此檔案移到另一個資料夾中 就跑不出來了~~ 出現以下的訊息 請問是哪裡出了問題呢~?? ??? Attempt to execute SCRIPT colormap as a function. Error in ==> colorbar>make_colorbar at 175 ch=scribe.colorbar(peeraxes,location,position,pvpairs{:}); Error in ==> colorbar at 142 [c,msg] = make_colorbar(peeraxes,location,position,pvpairs); Error in ==> colormap_XYc at 143 colorbar; 謝謝~~ -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 140.112.1.187

04/22 17:51, , 1F
不要用colormap.m 換個檔名吧,colormap是內建函數
04/22 17:51, 1F

04/24 10:45, , 2F
喔喔 我試試~~
04/24 10:45, 2F
文章代碼(AID): #1Bp_uw7G (MATLAB)