Unrecognized function or variable

1 次查看(过去 30 天)
Pwint Oo San
Pwint Oo San 2021-12-14
评论: Rik 2021-12-14
Hi, I want to develop future IDF curve using equidistant quantile matching. I used the following codes. I don't understand why I received the error message ' unrecognized function or variable 'data-hist'? Can anyone please help me? Thanks in advance.
% Fitting Gumbel Distribution
% Negative sign for Gumbel distribution
% Positive is for minimums for evfit
IDF = zeros(size(data_hist,2),length(P));
hist_error = zeros(size(data_hist,2),length(P));
future_change1 = zeros(size(data_hist,2),length(P));
future_change2 = zeros(size(data_hist,2),length(P));
IDF_gen = zeros(size(data_hist,2),length(P));
IDF_gen1 = zeros(size(data_hist,2),length(P));
IDF_gen2 = zeros(size(data_hist,2),length(P));
IDF_gen3 = zeros(size(data_hist,2),length(P));
mtrA = zeros(size(data_hist,2), 4);
mtrPar = zeros(size(data_hist,2), 6);
for i = 1:size(data_hist,2)
max_hist_con = data_hist(:,i);
  3 个评论
Pwint Oo San
Pwint Oo San 2021-12-14
To be honest, I don't understand you question. The data are imorted into the wokspace well. When I run the following code in command window.
% Load Input Data
% Includes: Sub-daily Maximums, GCM base period daily maximum, GCM future
% period daily maximum
load input_data
% Sub-daily Time Interval
subdaily = [5,10,15,30,60,120,360,720,1440];
% Return Period
RT = [2,5,10,25,50,100];
P = 1./RT;
This is my workspace.
Rik
Rik 2021-12-14
Where is data_hist?
As a side-note, you should not use load this way. It may overwrite variables without warning and it doesn't leave a trace what variables are loaded. Use something like this instead:
% Load Input Data
% Includes: Sub-daily Maximums, GCM base period daily maximum, GCM future
% period daily maximum
S=load('input_data.mat');
histSubDailyMaximums=S.histSubDailyMaximums;
GCMbaseperioddailymaximums=S.GCMbaseperioddailymaximums;
GCMfutureperioddailymaximums=S.GCMfutureperioddailymaximums;
% Sub-daily Time Interval
subdaily = [5,10,15,30,60,120,360,720,1440];
% Return Period
RT = [2,5,10,25,50,100];
P = 1./RT;

请先登录,再进行评论。

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Data Type Conversion 的更多信息

产品


版本

R2021b

Community Treasure Hunt

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

Start Hunting!

Translated by