Thingspeak: problem with a bar graph

19 ビュー (過去 30 日間)
Fabrice Auzanneau
Fabrice Auzanneau 2020 年 3 月 21 日
Hi
I'm trying to plot some measured values on bar graphs, but it seems that only a few values are plotted, not all of them.
Here is the code:
readChannelID = ***;
fieldID = 1;
readAPIkey = '****';
%% Read data %%
month = 3;
day = 21;
range = [datetime(2020,month,day,0,0,0),datetime(2020,month,day,23,59,59)];
[data,time] = thingSpeakRead(readChannelID,'Fields',1,'DateRange',range,'ReadKey', readAPIkey);
%% Vizualize data
hours = datetime(0,0,0,hour(time)+1,minute(time),second(time));
hours
data
bar (hours,data,'r');
The graph is plotted but the maximum plotted value is around 25, and the maximum value I get when displaying the value lists is 58.
The last values displayed for data are:
5
5
5
6
5
20
13
15
13
48
27
26
58
19
6
12
It seems only one value out of 5 is plotted. What did I miss?
Thanks for your help

回答 (0 件)

コミュニティ

その他の回答  ThingSpeak コミュニティ

カテゴリ

Help Center および File ExchangeThingSpeak についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by