wind_rose execution

조회 수: 8 (최근 30일)
Rajendra Sapkota
Rajendra Sapkota 2012년 3월 6일
I try to run the porgram but it show following error, I am using Matlab 2010a, how to correct it? Attempted to access i(1); index out of bounds because numel(i)=0. Error in ==> wind_rose at 238 d=dcircles(i(1));

채택된 답변

Matt Tearle
Matt Tearle 2012년 3월 6일
It looks like you're using a File Exchange submission called wind_rose. There's really no way to debug the problem without seeing how you're calling this function.
It looks like the line prior to the one giving the error is returning an empty array; one reason I could think of for that is that d (defined on the line before that) is NaN, but I can't see how that would occur.
Try setting a breakpoint on the line that gives the error and running the code. When it stops on that line and enters debug mode, look at the values of d and b.
  댓글 수: 2
Rajendra Sapkota
Rajendra Sapkota 2012년 3월 6일
Thanks Matt Actually I am learner of matlab and I need to use matlab in my porject. I have 2 yers wind data about 1 million data point. I have one column of wind direction in degree(0-360). I am not sure how call the program, i tried wind_rose(D,V,'ci',[1 2 7],'dtype','meteo') where assigned D= dir column, I have no idea for V and other parameter are standard defined in program. Could you please give me idea how to handle wind_rose?
Matt Tearle
Matt Tearle 2012년 3월 7일
I don't know anything about this particular function, but it looks like V should be a vector of the intensities (wind speeds), corresponding to the wind directions in D. I'd start by trying to call it as simply as possible: wind_rose(D,V) and see if that works. Then worry about adding in the options.
You can also always try contacting the author, if you need clarification about the technical details.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Programming에 대해 자세히 알아보기

태그

아직 태그를 입력하지 않았습니다.

Community Treasure Hunt

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

Start Hunting!

Translated by