MATLAB visualizations to do predictive algorithm and show average temperature | MATLAB | Forum

Avatar

Please consider registering
Guest

Search

— Forum Scope —






— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

Register Lost password?
sp_Feed sp_TopicIcon
MATLAB visualizations to do predictive algorithm and show average temperature
Avatar
decx

Silver
Forum Posts: 5
sp_UserOfflineSmall Offline
1
September 25, 2017 - 12:24 pm
sp_Permalink sp_Print

% Enter your MATLAB code below
readChId = 322698;
readKey = '548GQEP6OLOSFZIR';

writeChId = 334199;
writeKey = 'ERGWRT0AC8YB5B9Z';

[temp,timeStamps] = thingSpeakRead(readChId,'fields',[1],...
'NumPoints',100,'ReadKey',readKey);

thingSpeakWrite(writeChId,[tempAvg],'Fields',[1],...
'TimeStamps',timeStamps,'Writekey',writeKey);

thingSpeakPlot(timeStamps,tempAvg,'xlabel','TimeStamps',...
'ylabel','Avg Temp','title','Average temperature',...
'Legend',{'Avg Temperature'},'grid','on');

 

Above is my current code. I am doing a school project on machine monitoring and i need to calculate the average temperature of every 4 data inputted from the sensor i have(bosch xdk 110). Then find out what's the average working temp, so when there is anomaly in the temperature, the predictive algorithm can hopefully display it and send an alert to the user(thingtweet or twillio)

Please help me out with how i can make this current code find the average of every 4 data inputted and also how to write the predictive algorithm code as i've seen multiple codes but i don't understand it.

Forum Timezone: America/New_York

Most Users Ever Online: 114

Currently Online: jacktheripper125, pudderz
24 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

rw950431: 252

Vinod: 164

cstapels: 96

piajola: 75

vespapierre: 63

Adarsh_Murthy: 59

Newest Members:

bbruno22

pudderz

Utkya

Poornak26

LindasHed

reddysiva

Forum Stats:

Groups: 4

Forums: 17

Topics: 1313

Posts: 4565

 

Member Stats:

Guest Posters: 1

Members: 5703

Moderators: 0

Admins: 2

Administrators: Hans, lee