MATLAB 板


LINE

请问一下板上各位大大 我要跑 31年的水位资料 总共 26万多笔 利用老师给的hht程式去跑 不过好像发生了记忆体的问题 想问一下板上的大大如何解决 下面是程式码 http://ppt.cc/p5Zo 错误讯息如下 ??? Error using ==> horzcat Out of memory. Type HELP MEMORY for your options. Error in ==> wavedat2 at 24 Wavedat=[Period Height N]; Error in ==> hht51 at 26 Wavedat2=wavedat2(wheight,s_rate,ndata1); 下面是两个程式的 code 出问题的地方是在 我写成wavedat2里面 hht51 clear all;clc; w_data=load('height.txt');%height.txt是我的26万笔的资料文件 一维阵列 %w_data=spi070910(200*25:450*25,1); %name the data file ndata1=length(w_data); %no. of elements in original time series s_rate=25;t=[1:ndata1];t=t'/s_rate; % data time (hr) ************ gsta(:,1)=t; gsta(:,2)=w_data; figure(1) plot(gsta(:,1),gsta(:,2)); title('Experimtent ') xlabel('Time (s)') ylabel('Height (cm)') year=gsta(:,1); inData=gsta(:,2); rslt=eemd(inData,0,1); rslt1(:,1)=gsta(:,1); n=size(rslt);m3=0; for i=1:n(2)-1 rslt1(:,i+1)=rslt(:,i+1); end save hhtcase.dat rslt1 -ascii %save IMF for i=1:6 depth1(:,1)=rslt(:,i); wheight=depth1; stat=std(depth1); Wavedat2=wavedat2(wheight,s_rate,ndata1); Period=Wavedat2(:,1);Height=Wavedat2(:,2); N=Wavedat2(1,3); Tstat=tstat2(wheight, Period, Height, s_rate, ndata1, N); Hsig(i)=Tstat(1,5);Tsig(i)=Tstat(1,6); end if n(2)<=7 figure (2) for i1=1:n(2) i6=i1-1; subplot(n(2),1,i1) plot(year,rslt(:,i1)) ylabel(['T',num2str(i6),'=',num2str(Tsig(i1)),'s']); title(['A',num2str(i6),'=',num2str(Hsig(i1)),'cm']); end xlabel('Time (s)'); else m2=ceil(n(2)/7); for i2=2:m2+1 figure(i2) for i3=1:7 i4=m3+i3; i5=i4-1; if i4 > n(2) break end subplot(7,1,i3) plot(year,rslt(:,i4)); if i4<=6 ylabel(['T',num2str(i5),'=',num2str(Tsig(i4)),'s']); title(['A',num2str(i5),'=',num2str(Hsig(i4)),'cm']); else ylabel(['T',num2str(i5)]); end axis([0 max(year) min(rslt(:,i4)) max(rslt(:,i4))]); end xlabel('Time (s)'); m3=m3+7; end end Hi='finish...tpa.m !!' ---------------------------------------------------------------------- wavedat2的code如下: % wavdat.m %calculate the number of waves in the time series, their periods and heights% function Wavedat=wavedat2(wheight, s_rate, ndata1) %calculate number of waves in the time series by zero down-crossings% Nz=0;ndata=ndata1;x=wheight; for j=1:ndata-2 if (x(j)>0) & (x(j+1)<=0) Nz=Nz+1; %no. of zero down-crossings Xlnd(Nz,1)=j; %position in data where zero crossing occurs end end N1=Nz-1; %no. of waves in time series% %determine the period, crest, trough and height of each wave in the time series% Period=(diff(Xlnd))./s_rate; %find the period of waves% for k= 1:N1 %find height of waves% wave=x((Xlnd(k)+1 ):Xlnd(k+1)); crest(k,1)=max(wave); trough(k,1)=abs(min(wave)); Height(k,1)=crest(k,1)+trough(k,1); end Nc=length(crest)+length(trough); %no. of optima in time series% N=zeros(length(Period)); %for display purposes only% N(1,1)=N1; Wavedat=[Period Height N];%有问题的地方 想请问一下板上的大大如何解决!!! 感谢!! --



※ 发信站: 批踢踢实业坊(ptt.cc)
◆ From: 118.167.163.1







like.gif 您可能会有兴趣的文章
icon.png[问题/行为] 猫晚上进房间会不会有憋尿问题
icon.pngRe: [闲聊] 选了错误的女孩成为魔法少女 XDDDDDDDDDD
icon.png[正妹] 瑞典 一张
icon.png[心得] EMS高领长版毛衣.墨小楼MC1002
icon.png[分享] 丹龙隔热纸GE55+33+22
icon.png[问题] 清洗洗衣机
icon.png[寻物] 窗台下的空间
icon.png[闲聊] 双极の女神1 木魔爵
icon.png[售车] 新竹 1997 march 1297cc 白色 四门
icon.png[讨论] 能从照片感受到摄影者心情吗
icon.png[狂贺] 贺贺贺贺 贺!岛村卯月!总选举NO.1
icon.png[难过] 羡慕白皮肤的女生
icon.png阅读文章
icon.png[黑特]
icon.png[问题] SBK S1安装於安全帽位置
icon.png[分享] 旧woo100绝版开箱!!
icon.pngRe: [无言] 关於小包卫生纸
icon.png[开箱] E5-2683V3 RX480Strix 快睿C1 简单测试
icon.png[心得] 苍の海贼龙 地狱 执行者16PT
icon.png[售车] 1999年Virage iO 1.8EXi
icon.png[心得] 挑战33 LV10 狮子座pt solo
icon.png[闲聊] 手把手教你不被桶之新手主购教学
icon.png[分享] Civic Type R 量产版官方照无预警流出
icon.png[售车] Golf 4 2.0 银色 自排
icon.png[出售] Graco提篮汽座(有底座)2000元诚可议
icon.png[问题] 请问补牙材质掉了还能再补吗?(台中半年内
icon.png[问题] 44th 单曲 生写竟然都给重复的啊啊!
icon.png[心得] 华南红卡/icash 核卡
icon.png[问题] 拔牙矫正这样正常吗
icon.png[赠送] 老莫高业 初业 102年版
icon.png[情报] 三大行动支付 本季掀战火
icon.png[宝宝] 博客来Amos水蜡笔5/1特价五折
icon.pngRe: [心得] 新鲜人一些面试分享
icon.png[心得] 苍の海贼龙 地狱 麒麟25PT
icon.pngRe: [闲聊] (君の名は。雷慎入) 君名二创漫画翻译
icon.pngRe: [闲聊] OGN中场影片:失踪人口局 (英文字幕)
icon.png[问题] 台湾大哥大4G讯号差
icon.png[出售] [全国]全新千寻侘草LED灯, 水草

请输入看板名称,例如:BuyTogether站内搜寻

TOP